On Sun, Apr 10, 2011 at 6:17 PM, ali hagigat <hagigat...@gmail.com> wrote:

> How can i specify a multi line shell instruction as a recipe? The
> following returns an error:
>
> makefile27:
> e14:
>        @echo var1=$(var1)
>
> makefile25:
> include makefile27
> e12:
>        @echo insidee12
> makefile27: e13
>        if ( test $$count -eq 0) then echo "all: ;echo ppp" >
> makefile27;count=1;fi
>

When you test $count it's not assigned with a value yet.


> e13: ;
>
> make -f makefile25
> if ( test $count -eq 0) then echo "all: ;echo ppp" > makefile27;count=1;fi
> /bin/sh: line 0: test: -eq: unary operator expected
> var1=
>
> Why it complains about needing a unary operator?
>
>
-- 
Clark J. Wang

Reply via email to