##########################################################################
# Copyright 1992 to 1998 MBARI                                            
##########################################################################
# Summary  : Makefile for 
# Filename : Makefile
# Author   : 
# Project  : 
# Version  : Version 1.0
# Created  : 04/16/98
# Modified : 04/16/98
# Archived :
##########################################################################
# Modification History:
# $Header: $
# $Log:    $
#
##########################################################################
#
# This is a makefile template that can be used to build vxWorks and
# unix applications. One feature of this makefile it the automatic 
# generation of header file dependency information which is stored in
# .d files in the source code directory.
#
# The makefile assumes the environment variables VW and MBARI_VW are
# set to point to the vxWorks directory base and MBARI vxWorks code
# base respectively. It also assumes the use of CFLAGS for defining
# compiler options. The complier defined by CC must support the -M
# option for generating automatic dependency information.
#
# To use this makefile for your application, modify the following:
# 
# 1. Define the name of the application in the macro PROGRAM.
# 2. Add the names of any library files that you need linked with the
#    application program to the LIBS macro.
# 3. Add the names of any C source code files that you need compiled and
#    linked to your application by to the SRCS macro.
# 4. Add the names of any C++ source code files that you need compiled and
#    linked to your application by to the CC_SRCS macro.
#
###########################################################################

TIBURON     = /usr/tiburon
XPLATFORM   = /usr/tiburon/xPlatform
MICRO_APP   = $(MBARI_VW)/microApp

CC	    = cc68k
LD	    = ld68k

DEBUG 	    = -g

CFLAGS 	    = $(DEBUG) -c -m68040 -ansi -pipe -nostdinc -fno-builtin \
              -DCPU=MC68040 -DINCLUDE_PROTOTYPES $(IFLAGS)

CCFLAGS     = $(DEBUG) -c -m68040 -ansi -pipe -nostdinc -fno-builtin \
              -DCPU=MC68040 -DINCLUDE_PROTOTYPES $(IFLAGS)

IFLAGS	    =  	-I/usr/tiburon/dm/vw \
		-I$(XPLATFORM)/iview \
		-I$(MBARI_VW)/h	\
                -I$(XPLATFORM)/utils \
		-I$(XPLATFORM)/datamgr \
		-I$(VW)/target/h \
		-I$(MICRO)/h \
		-I$(MICRO)/lapbox \
                -I$(MICRO_APP) \
                $(NULL)

LDFLAGS     = -r

LIBS	    = 
	      
VPATH	    = ../

PROGRAM	    = lapBox

SRCS        = 

CC_SRCS	    =  LapBox.cc \
	       LapBoxMicro.cc \
	       LapBoxTaskControl.cc \
               DeviceLight.cc \
	       LapBoxApp.cc \
	       LapBoxInTask.cc \
	       LapBoxOutTask.cc  

OBJS	    = $(SRCS:.c=.o) $(CC_SRCS:.cc=.o)

all:          $(PROGRAM)

$(PROGRAM):   $(OBJS) $(LIBS) Makefile
	      $(LD) -r $(OBJS) $(LIBS) -o $(PROGRAM)

##########################################################################
# Do not modify anything below this line unless absolutely necessary

%.d: %.c
	    @echo Generating dependencies for $?
	    @$(CC) -M $(CFLAGS) $? > $@

%.d: %.cc
	    @echo Generating dependencies for $?
	    @$(CC) -M $(CCFLAGS) $? > $@

%.o: %.c
	    $(CC) $(CFLAGS) $< -o $@	

%.o: %.cc
	    $(CC) $(CCFLAGS) $< -o $@

DEST	    = .

INSTALL     = install

MAKEFILE    = Makefile

include       $(SRCS:.c=.d) $(CC_SRCS:.cc=.d)

depend:	
	    
echo:;        @echo $(PROGRAM) from $(SRCS) $(CC_SRCS)

clean:
	      rm -f $(PROGRAM) $(OBJS) $(OBJS:.o=.d)

get_release:


put_release:

##########################################################################







