www.delorie.com/gnu/docs/make/make_23.html   search  
 
Buy the book!


GNU make

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

4.1 Rule Example

Here is an example of a rule:

 
foo.o : foo.c defs.h       # module for twiddling the frobs
        cc -c -g foo.c

Its target is `foo.o' and its prerequisites are `foo.c' and `defs.h'. It has one command, which is `cc -c -g foo.c'. The command line starts with a tab to identify it as a command.

This rule says two things:


  webmaster   donations   bookstore     delorie software   privacy  
  Copyright © 2003   by The Free Software Foundation     Updated Jun 2003  

Please take a moment to fill out this visitor survey
You can help support this site by visiting the advertisers that sponsor it! (only once each, though)