
AMBLES=./POSTAMBLE ./INAMBLE
PICS= bigtree.gif fork1a.gif fork1b.gif fork2a.gif fork2b.gif fork2c.gif \
	smalltree.gif

PS2GIF = ps2gif
GIF2PPM = /usr/local/bin/pbm/ppmtogif

.SUFFIXES: .ps .gif .pic .plot .ppm .pl

.plot.ppm: 
	gnuplot < $*.plot

.ppm.gif:
	$(GIF2PPM)  $*.ppm > $*.gif

.ps.gif: 
	$(PS2GIF) < $*.ps > $*.gif

.pic.ps: 
	pic $*.pic | groff > $*.ps

default: $(PICS)

bigtree.pic: bigtree.pl
	perl bigtree.pl 5 > bigtree.pic

smalltree.pic: bigtree.pl 
	perl bigtree.pl 3 > smalltree.pic
#	cat smalltree-pipe.pic >> smalltree.pic

fork1a.pic: bigtree.pl
	perl bigtree.pl 1 0 0 > fork1a.pic

fork1b.pic: bigtree.pl
	perl bigtree.pl 1 > fork1b.pic

fork2a.pic: bigtree.pl
	perl bigtree.pl 2 0 0 1 1 > fork2a.pic

fork2b.pic: bigtree.pl
	perl bigtree.pl 2 0 0 2 2 > fork2b.pic

fork2c.pic: bigtree.pl
	perl bigtree.pl 2 > fork2c.pic
