#
# Application Makefile   
#

ifndef DEBUG
DEBUG = -g1
endif

ifndef OPTIM
OPTIM = -Osax
endif

PLATFORM=nto
#
CFLAGS  = -v$(PLATFORM) -3 -mf -w5 -b -D__NEUTRINO__ $(OPTIM) $(DEBUG) -I /src/photon/include
LDFLAGS = -v$(PLATFORM) -3 -mf -b $(DEBUG) -l /src/photon/lib/nto/photon3r -l phcontrib -l phexlib -l phrtlib -l Aplib3r 
SDFLAGS = -v$(PLATFORM) -3 -mf -b $(DEBUG) -l photon_s -l phcontrib -l phexlib -l phrtlib -l Aplib3r 

VPATH = ../.

include	../abOfiles
include ../indOfiles

include	../abSfiles
include ../indSfiles

include	../abHfiles
include ../indHfiles

#
# Application Program
#

shr:	$(ABOBJ) $(MYOBJ)
		$(LD) $(SDFLAGS) $(ABOBJ) $(MYOBJ) -M \
		-o phcd
		usemsg phcd ../abmain.c
		phabbind phcd

app:	$(ABOBJ) $(MYOBJ)
		$(LD) $(LDFLAGS) $(ABOBJ) $(MYOBJ) -M \
		-o phcd
		usemsg phcd ../abmain.c
		phabbind phcd

clean:
		rm -f *.o *.err phcd

install:
		-cp -vnf phcd /usr/bin/photon

#
# Headers
#

$(ABOBJ) $(MYOBJ):	$(MYHDR)

#
# Prototype Generation
#

proto:
		approto -p $(ABSRC) $(MYSRC) > proto.h
