#-------------------------------------------------------------------------
# common part of the makefile for the PSI specific parts of SICS
#
# Mark Koennecke, June 2003
#-------------------------------------------------------------------------
.SUFFIXES: 
.SUFFIXES: .c .o .f .tc

.tc.c: 
	tjxp $*.tc $*.c

OBJ=psi.o buffer.o ruli.o  sps.o pimotor.o \
	pipiezo.o sanswave.o faverage.o   spss7.o\
	amorstat.o tasinit.o ptasdrive.o tasutil.o tasscan.o swmotor.o \
	polterwrite.o ecb.o frame.o sqlitelog.o mongolog.o sicslogquery.o \
	approxidate.o el737driv.o sinqhmdriv.o tdchm.o  \
	sanscook.o itc4driv.o itc4.o\
	bruker.o ltc11.o   eurodriv.o \
	el755driv.o  serial.o scontroller.o  t_update.o \
	t_rlp.o t_conv.o el737hpdriv.o  el734hp.o \
	el737hpv2driv.o swmotor2.o tricssupport.o amorcomp.o \
	$(MZOBJ) amordrive.o amorset.o  sinqhttp.o slsecho.o\
	dgrambroadcast.o sinq.o tabledrive.o   sinqhttpopt.o\
	ritastorage.o  el737hpdrivsps.o \
	rebin.o sanslirebin.o lmd200.o slsvme.o julprot.o sinqhttpprot.o \
	pfeifferprot.o termprot.o phytron.o autowin.o eigera2.o \
	jvlprot.o  \
	eigermono.o sputterprot.o zwickroll.o astriumnet.o poldifold.o \
	epicsadapter.o zebraswap.o

.SECONDARY.: sanslirebin.c

MZOBJ=fsm.o sugar.o pardef.o ease.o strobj.o oxinst.o \
	ipsdriv.o ilmdriv.o itcdriv.o ighdriv.o euro2kdriv.o modbus.o arrobj.o \
	linadriv.o haakedriv.o seaclientprot.o dumprot.o

libpsi.a: $(OBJ)
	rm -f libpsi.a
	ar cr libpsi.a $(OBJ)
	ranlib libpsi.a

clean:
	rm -f *.a *.o *.d

SINQOPT=-DGRAPH_MHC3 -DUSE_MULTICAST -DSEND_PORT=0xABCB -DSERVER_HOST="\"hipa129-sta\""
dgrambroadcast.o: dgrambroadcast.h dgrambroadcast.c
	$(CC) $(SINQOPT) -c -g dgrambroadcast.c

sinq.o: sinq.c sinq.h dgrambroadcast.h
	$(CC) -I$(TCLINC) $(SINQOPT) -I$(SICSROOT)/sics -g -c sinq.c
