[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: macro reuse
From: |
Ralf Wildenhues |
Subject: |
Re: macro reuse |
Date: |
Mon, 22 May 2006 18:02:18 +0200 |
User-agent: |
Mutt/1.5.11 |
* Keith MARSHALL wrote on Mon, May 22, 2006 at 05:48:48PM CEST:
> Stepan Kasal wrote, quoting Thomas Porschberg:
> >> My idea was to call AC_REQUIRE([M1([$version_number])]) but it does
> >> not work.
> >
> > it would help if you posted some example code. Preferably a pointer
> > to a small self-contained example, but simple pointer to a tarball of
> > your project might be enough.
>
> Isn't it likely that, the problem here is that parameters cannot be
> passed to an AC_REQUIREd macro?
That is not strictly true. It'd undocumented (and as such you shouldn't
rely on it), but you can
AC_REQUIRE([FOO], [FOO([arg])])
However, it won't help you the way Thomas would probably need: a later
AC_REQUIRE([FOO], [FOO([another arg])])
will, after the first one has been satisfied, not lead to another
expansion of FOO with the other argument. So it's better not to rely
on this.
Depending on the specific needs, a different nice solution is possible;
but we'd need to know more about the problem.
Cheers,
Ralf
Re: macro reuse, Familie Porschberg, 2006/05/22
Re: macro reuse, Thomas Porschberg, 2006/05/24