#	START NEW ARIX SCCS HEADER
#
#	@(#) Makefile: version 25.1 created on 12/2/91 at 15:16:33
#
#	Copyright (c) 1990 by Arix Corporation
#	All Rights Reserved
#
#	@(#)Makefile	25.1	12/2/91 Copyright (c) 1990 by Arix Corporation
#
#	END NEW ARIX SCCS HEADER
#
#	Copyright (c) 1984 AT&T
#	  All Rights Reserved

#	THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T
#	The copyright notice above does not evidence any
#	actual or intended publication of such source code.

#	ATT:#ident	"graf:src/toc.d/Makefile	1.6"

#ident	"@(#)graf/src/toc.d:Makefile	25.1"

include	$(IROOT)/macdefs

###
### Standard Constants
###

LROOT    =
BIN      = $(ROOT)/$(LROOT)/usr/bin/graf
CFLAG   = -c $(CFLAGS) $(FFLAG)


###
### Local Constants
###

USRLIB   = $(ROOT)/$(LROOT)/usr/lib

##### Dependencies

all:  ttoc dtoc

install     :  dtoc  ttoc
	
	-if test ! -d $(USRLIB)/graf; then  \
	  mkdir $(USRLIB)/graf;            \
	  chmod 755 $(USRLIB)/graf;        \
        fi
	-if test ! -d $(USRLIB)/graf/ttoc.d; then  \
	  mkdir $(USRLIB)/graf/ttoc.d;            \
	  chmod 755 $(USRLIB)/graf/ttoc.d;        \
	fi
	chgrp bin $(USRLIB)/graf $(USRLIB)/graf/ttoc.d
	chown bin $(USRLIB)/graf $(USRLIB)/graf/ttoc.d
	
	$(INS) ttoc $(BIN)/ttoc
	chmod 755 $(BIN)/ttoc
	chgrp bin $(BIN)/ttoc
	chown bin $(BIN)/ttoc
	$(INS) ed.notoc $(USRLIB)/graf/ttoc.d/ed.notoc
	chmod 644 $(USRLIB)/graf/ttoc.d/ed.notoc
	chgrp bin $(USRLIB)/graf/ttoc.d/ed.notoc
	chown bin $(USRLIB)/graf/ttoc.d/ed.notoc
	$(INS) ed.toc $(USRLIB)/graf/ttoc.d/ed.toc
	chmod 644 $(USRLIB)/graf/ttoc.d/ed.toc
	chgrp bin $(USRLIB)/graf/ttoc.d/ed.toc
	chown bin $(USRLIB)/graf/ttoc.d/ed.toc
	$(INS) ed.ttoc.t $(USRLIB)/graf/ttoc.d/ed.ttoc.t
	chmod 644 $(USRLIB)/graf/ttoc.d/ed.ttoc.t
	chgrp bin $(USRLIB)/graf/ttoc.d/ed.ttoc.t
	chown bin $(USRLIB)/graf/ttoc.d/ed.ttoc.t
	$(INS) dtoc $(BIN)/dtoc
	chmod 755 $(BIN)/dtoc
	chgrp bin $(BIN)/dtoc
	chown bin $(BIN)/dtoc

ttoc        :  ttoc.sh
	cp ttoc.sh ttoc
	chmod 555 ttoc

dtoc        :  dtoc.sh
	cp dtoc.sh dtoc
	chmod 555 dtoc

########

clobber     :      ;
	-rm -f dtoc ttoc

clean:

listings    :      ;
	ls -l *.sh | pr -h "    toc  source files " | pr
