help-make
[Top][All Lists]
Advanced

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

Re: 3 dumb questions


From: John Graham-Cumming
Subject: Re: 3 dumb questions
Date: Wed, 19 Apr 2006 15:11:00 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040208 Thunderbird/0.5 Mnenhy/0.6.0.104

PATTON, BILLY (SBCSI) wrote:
1.  Must .PHONY begin in column 1 ?
2.  Must a target begin in column 1?
3.  Is leading space ignored ? (on the make side of syntax)

What I would like to do, for readability, I like indention :)

ifeq blabla

  .PHONY : test t_a t_b

  test : t_a t_b

  t_a :

  t_b :

endif

No, no, yes.

Try this out:

 .PHONY : test t_a t_b

  test : t_a t_b
      @echo Making $@

  t_a :
      @echo Making $@

  t_b :
      @echo Making $@

The only gotcha I can see here is that the lines that start with tab have to start with tab. i.e. you can't do space tab @command, and vice cersa. Basically, you need to respect tab's meaning.

Apart from that you can indent with spaces if you feel like it.

John.





reply via email to

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