#
# combine all .gif icons into a single one
# needs PPM utilities
#
# created: mpichler, 19970917
# changed: mpichler, 19970917


all: ../icons.gif

# why did this not work?
#.gif.ppm:
#	giftopnm $< > $@
#
#.SUFFIXES:
#	.gif

# giftopnm not necessarily writes PPM, but pnmcat can combine all PGMs as well

flip.ppm: flip.gif
	giftopnm $? > $@

walk.ppm: walk.gif
	giftopnm $? > $@

flyto.ppm: flyto.gif
	giftopnm $? > $@

headsup.ppm: headsup.gif
	giftopnm $? > $@

behavior.ppm: behavior.gif
	giftopnm $? > $@

interact.ppm: interact.gif
	convert $? $@
# following would create a PBM, which pnmcat reads b/w; convert with ImageMagick instead
#	giftopnm $? > $@

anchor.ppm: anchor.gif
	giftopnm $? > $@

# order must be as read out by Iconbar

icons.ppm: flip.ppm walk.ppm flyto.ppm headsup.ppm behavior.ppm interact.ppm anchor.ppm
	pnmcat -lr flip.ppm walk.ppm flyto.ppm headsup.ppm behavior.ppm interact.ppm anchor.ppm > $@

../icons.gif: icons.ppm
	ppmtogif -transparent "#CCCCCC" $? > $@

clean:
	rm -f *.ppm *~
