[Omake] error when defining a rule inside of a function
Erick Tryzelaar
erickt at dslextreme.com
Sat Jan 13 12:55:30 PST 2007
Erick Tryzelaar wrote:
> Erick Tryzelaar wrote:
>> Hmm, this led me to a stack overflow, with this OMakefile:
>
> Here's a smaller file that still has the Stack_overflow:
>
> OMakefile:
> comflags(sources) =
> return $(sources)
>
> make-rule(target, sources) =
> $(target):
> echo $(comflags $(sources))
> return $(target)
>
> .DEFAULT: $(make-rule cmain, foo)
And I found a work around, by saving the output of the function outside
of the rule, like this:
comflags(sources) =
return $(sources)
make-rule(target, sources) =
x = $(comflags $(sources))
$(target):
echo $x
return $(target)
.DEFAULT: $(make-rule cmain, foo)
More information about the Omake
mailing list