###############################################################################
# TclRobots 
# Makefile
# Tom Poindexter
#

###############################################################################
# Only the following three defines need to be customized
#

#
# the full path of your wish interpreter

WISH_EXEC = /usr/local/bin/wish

#
# the full path where you would like tclrobots installed

BIN_DIR   = /usr/local/bin

#
# the full path where you would like tclrobots man page installed

MAN_DIR   = /usr/local/man/man6


###############################################################################
#

install:	
	sed -e '1s@^.*$$@#!$(WISH_EXEC) -f@p' \
	    -e '2s@^.*$$@set wishexec $(WISH_EXEC)@p' \
	    -e '3,$$p' \
	    -n <tclrobots.tcl >$(BIN_DIR)/tclrobots
	chmod 755 $(BIN_DIR)/tclrobots

install-man:
	cp tclrobots.man  $(MAN_DIR)/tclrobots.6

ascii-man:
	tbl tclrobots.man | nroff -man | col -bx > tclrobots.txt
	#groff -Tascii -t -man tclrobots.man | col -bx > tclrobots.txt

post-man:
	groff -Tps -t -man tclrobots.man            > tclrobots.ps

mkshar:	
	shar -n1 -e2 -opart01 README Makefile tclrobots.man samples samples/*
	shar -n2 -e2 -opart02 tclrobots.tcl

mktar:
	tar cvf tclrobots-1.0.tar README Makefile tclrobots.man tclrobots.txt \
	                          tclrobots.ps tclrobots.tcl samples

	gzip -f tclrobots-1.0.tar
