bug-gnulib
[Top][All Lists]
Advanced

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

Re: gengetopt, anyone?


From: Bruce Korb
Subject: Re: gengetopt, anyone?
Date: Tue, 27 Sep 2011 08:37:52 -0700
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.18) Gecko/20110616 SUSE/3.1.11 Thunderbird/3.1.11

On 09/27/11 06:49, Simon Josefsson wrote:
Reuben Thomas<address@hidden>  writes:

Has anyone else any experience with it?

I have used it in libidn, gsasl and a few other projects since well over
5 years.  I have been quite happy with it.

The biggest concern I have had is that the auto-generated --help screen
is impossible to fine-tune and it doesn't look as good as I want it to.

For Libidn, I have given up on using the auto-generated --help output
and instead wrote a custom function for displaying it.  For gsasl I
still use the auto-generated screen, mostly due to the much larger
amount of parameters.

One of the things I want to go away is that it prints the project name
and version as the first line of --help, I think there is no point in
having that there (there is --version after all) and I would prefer a
terse Usage:-line instead.

I have also played with it, and tried to combine my "autoopts" strengths
with Lorenzo, but he seemed pointedly uninterested.  In the end, there
is little gengetopt does that is not well covered by autoopts:

  http://www.gnu.org/software/autogen/compare.html

and it is more easily covered in autoopts.

WRT "fair amount of work", I'd have to agree with Jim.  It is
an understatement.  The problem being that since each program basically
parses its own options (getopt() and getopt_long() being only very
minor assists), and has non-standard-isms in the way they are handled.
You'd have to go back to the generator engine and add a lot of
"exceptional handling" code.  Not worth it.

BTW, current NTP code uses autoopts for handling its options and
configuration files and multi-flavored man pages.

Cheers - Bruce



reply via email to

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