DragonFly submit List (threaded) for 2004-05
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
Re: small enhancement idea for 'make installworld' et al.
On Wed, 12 May 2004 07:04:31 +0200
Jeroen Ruigrok/asmodai <asmodai@xxxxxx> wrote:
> >...is repeated four times in the patch. This is exactly the sort of
> >thing that should be abstracted into a procedure - except I'm not
> >sure how to do that with make(1), which doesn't have procedures (that
> >I'm aware of.) I'm sure there's a way to hack it up - but that
> >raises the question of what's uglier. At least the cut-and-pasted
> >version would have the advantage of having fairly obvious behaviour.
>
> Make a macro with the use of .USE.
Thanks for pointing that out, but I can't get it to work here. All the
common code is wrapped in conditionals like this:
target:
. if <common conditional>
<common code>
. else
<target-specific code>
. endif
And .USE appends to the bottom of the target - outside the conditional.
There may be a way to pass the target-specific code to the .USE macro,
but that's the sort of obfuscating hack-up I was referring to.
But more importantly: do you think this sort of change (auto-su'ing) is
worthwhile? Would it save you time/effort/frustration, even a small
amount?
-Chris
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]