########################################################################
#                 copyright 2001, Amoco Production Company             #
#                             All Rights Reserved                      #
#                     an affiliate of BP America Inc.                  #
########################################################################


# gmake Makefile for src/lib/xtb
# Bill Done	89/9/13
# convert David Harrison's xtb Makefile to one for our gmake system

include	${DEPTROOT}/etc/gmake.init
include	${DEPTROOT}/etc/gmake.motif1.2

sun3CCFlags	:=	-DSUN -O
sun3fpaCCFlags	:=	-DSUN -ffpa -O
sun4CCFlags	:=	-DSUN -O
cray2CCFlags	:=	-DCRAY

# CIncludes	:=	${strip -I/usr/include/X11 ${CIncludes} }

LIB	:=	${LocalLib}/libxtb.a

CSrcs		:=	xtb.c

SafeFiles	:=	${CSrcs} Makefile ${wildcard *.h} ${wildcard READ*}

.PHONY:	all safe remotes targets 

targets:	${LIB}

all :	safe targets remotes

${LIB}:	${CObjs}
	ar rv ${LIB}	$?
	${RANLIB} ${LIB}

remotes:	RemoteCopies RemoteMakes

RemoteCopies:	${SafeFiles}
	shadowcopy -v $?
	touch RemoteCopies

RemoteMakes:	${SafeFiles}
	shadowexec ${MAKE}
	touch RemoteMakes

include	${TArchDir}/included.files

${TArchDir}/included.files: ${AllSrcs}
	${FindIncludes}

safe:	.safe.${jdate}.Z

.safe.${jdate}.Z:	${SafeFiles}
	${MakeSafe}

clean:
	-rm ${TArchDir}/included.files ${AllObjs} \
	RemoteCopies RemoteMakes
