# Generated automatically from Makefile.in by configure.
#
# tools/Makefile.in  --
#
# Makefile for building tools used during install
#------------------------------------------------------------------------------
# Copyright 1992-1994 Karl Lehenbauer and Mark Diekhans.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose and without fee is hereby granted, provided
# that the above copyright notice appear in all copies.  Karl Lehenbauer and
# Mark Diekhans make no representations about the suitability of this
# software for any purpose.  It is provided "as is" without express or
# implied warranty.
#------------------------------------------------------------------------------
# $Id: Makefile.in,v 4.0 1994/07/16 05:28:50 markd Rel $
#------------------------------------------------------------------------------
#
SHELL = /bin/sh

#------------------------------------------------------------------------------

CC          = cc
srcdir      = .
srcbasedir  = /usr/src/tclX7.3b
bldbasedir  = /usr/src/tclX7.3b
prefix      = /usr/local
exec_prefix = /usr/local
XINCLUDES   =  -I/usr/X386/include
LIBS        =   -lbsd -lieee -lm

include ${bldbasedir}/Config.mk

#------------------------------------------------------------------------------

CC_FLAGS = ${CPPFLAGS} ${XCFLAGS} ${CFLAGS} -I${srcbasedir}/src \
           ${XINCLUDES} -I${TCL_UCB_SRC}

.c.o:
	${CC} ${CC_FLAGS} -c $<

#------------------------------------------------------------------------------

all: tclxversion $(TK_BUILD) instcopy bldmanhelp cpmanpages cphelpdir \
     symlinkext

tclxversion: getversion.c
	$(CC) $(CC_FLAGS) ${srcdir}/getversion.c -o tclxversion ${LIBS}

WISHX: tkxversion

tkxversion: getversion.c
	$(CC) $(CC_FLAGS) -I$(TK_UCB_SRC) -DTK_GET_VERSION \
	   ${srcdir}/getversion.c -o tkxversion ${LIBS}

instcopy: instcopy.tcl buildutil.tcl
	rm -f instcopy
	cat ${srcdir}/buildutil.tcl ${srcdir}/instcopy.tcl >instcopy

bldmanhelp: bldmanhelp.tcl
	rm -f bldmanhelp
	cp ${srcdir}/bldmanhelp.tcl bldmanhelp

cpmanpages: cpmanpages.tcl buildutil.tcl
	rm -f cpmanpages
	cat ${srcdir}/buildutil.tcl ${srcdir}/cpmanpages.tcl >cpmanpages

cphelpdir: cphelpdir.sh
	rm -f cphelpdir
	echo ":"                           >cphelpdir
	echo "TOOLS=${bldbasedir}/tools"  >>cphelpdir
	cat ${srcdir}/cphelpdir.sh        >>cphelpdir
	chmod a+x cphelpdir

symlinkext: symlinkext.sh
	rm -f symlinkext
	cat ${srcdir}/symlinkext.sh  >symlinkext
	chmod a+x symlinkext

#------------------------------------------------------------------------------

clean:
	-rm -f tclxversion tkxversion *.o
	-rm -f instcopy bldmanhelp cpmanpages cphelpdir symlinkext

#------------------------------------------------------------------------------
# Restore to the distributed state.

distclean: clean
	rm -f Makefile
