bug-gnulib
[Top][All Lists]
Advanced

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

[Bug-gnulib] Re: Docs for gnulib-tool --import


From: Gary V. Vaughan
Subject: [Bug-gnulib] Re: Docs for gnulib-tool --import
Date: Wed, 06 Oct 2004 16:37:17 +0100
User-agent: Mozilla Thunderbird 0.8 (X11/20040913)

Hi Simon,

Simon Josefsson wrote:
> "Gary V. Vaughan" <address@hidden> writes:
> >
> > I think I would rather see less macros, like this:
> >
> > AC_PROG_CC
> > gl_EARLY
> > ...
> > gl_MODULES([getopt progname strdup dummy ...])
> > gl_INIT([gl], [gl/m4], [libgl])
> > ...
> >
> > where defaults are used if the arguments are missing instead of needing a
> > whole extra macro call.
> 
> 
> Yes, I agree.  I'm experimenting with something inspired by your other
> post, e.g.:
> 
> gl_INIT([getopt progname strdup dummy ...], [gl], [gl/m4], [libgl], [LGPL])
> 
> Or possibly something like:
> 
> gl_INIT([[strdup dummy ...], [lgl], [lgl/m4], [liblgl], [LGPL]],
>         [[error getopt progname ...], [gl], [gl/m4], [libgl]])

Yes please!  That would be cool :-)

> Renaming LTLIBOBJ variable temporarily worked, but I haven't not
> tested all combinations (e.g., with/without libtool).
> 
> I don't think we can get rid of gl_EARLY, though, unless it is
> possible to hook into AC_PROG_CC automatically somehow.

AC_PROVIDE_IFELSE([AC_PROG_CC], [gl_EARLY],
    [m4_define([AC_PROG_CC], defn([AC_PROG_CC])[gl_EARLY])])

That is: If AC_PROG_CC has been expanded at this point, expand gl_EARLY right
now, otherwise hook it onto the end of AC_PROG_CC so that it will be expanded
right after the next call to AC_PROG_CC.

> I wish there were some non-positional way to specify function
> parameters in M4, though.  E.g., lisp inspired:
> 
> gl_INIT(:module [getopt progname strdup dummy ...], :sourcebase [gl], 
> :license [LGPL])

Something like this is slated for after the 2.0 release (which will happen as
soon as the dust settles on the libtool-2.0 release).

gl_INIT([module=getopt progname strdup ...], [sourcebase=gl], [license=LGPL])

I might be able to tweak the syntax table implementation to allow a lispier
notation too...

Cheers,
        Gary.
-- 
Gary V. Vaughan      ())_.  address@hidden,gnu.org}
Research Scientist   ( '/   http://tkd.kicks-ass.net
GNU Hacker           / )=   http://www.gnu.org/software/libtool
Technical Author   `(_~)_   http://sources.redhat.com/autobook

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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