# $Id: Makefile,v 1.4 91/11/18 17:53:10 sharakan Exp $ 
#*****************************************************************************
# 	  (c) Copyright  1989 Thinking Machines Corporation, Inc.,	     *
#		of Cambridge, Mass.   All rights reserved.		     *
#									     *
#  This notice is intended as a precaution against inadvertent publication   *
#  and does not constitute an admission or acknowledgement that publication  *
#  has occurred or constitute a waiver of confidentiality.		     *
#									     *
#  Connection Machine software is the proprietary and confidential property  *
#  of Thinking Machines Corporation.					     *
#****************************************************************************/

#
# Makefile for user-configurable CMFS file server
#
FILES= Makefile MaxVideo.c

INCLUDE=-I. -I../h -I../../CMFS_release/h
DEFS=-DFILE_SERVER
CFLAGS=-g ${DEFS} ${INCLUDE}

#
# If you include the MaxVideo driver, 
# set these up correctly for your site.
#
MAXINCLUDE=-I/local/max-video/include
MAXLIBDIR=/local/max-video/lib
MAXLIBS=$(MAXLIBDIR)/scilib.a $(MAXLIBDIR)/vdilib.a \
	$(MAXLIBDIR)/vmilib.a $(MAXLIBDIR)/mvlib.a

OBJECTS=/usr/local/etc/fsserver.o cm_conf.o MaxVideo.o

fsserver: $(OBJECTS)
	rm -f xfsserver
	cc -o xfsserver ${OBJECTS} $(CFLAGS)
	rm -f fsserver
	mv xfsserver fsserver


MaxVideo.o: MaxVideo.c
	$(CC) -c $(CFLAGS) $(MAXINCLUDE) MaxVideo.c -o temp.o
	ld -r -o MaxVideo.o temp.o ${MAXLIBS} 


release:
	-mkdir $(RELDIR)/examples/maxvideo-driver
	cp $(FILES) $(RELDIR)/examples/maxvideo-driver

clean:
	-rm -f fsserver *.o
