#-----------------------------------------------------------------------------
#
# make libs	- build library routines and install them in the appropriate
#		  modules in ../lib
#
# make install	- build the program rciProbe in ../bin
#
# make <prog>	- build a particular program.
#
#-----------------------------------------------------------------------------

CFLAGS = $(RCC_CFLAGS) -g

# program to test the IO driver allocator and interface
rccTestProgram(iotest,IOdriver.to,,$(LCTRL))

# program to peek and poke the rciBus and rciIOPage address spaces 
rccProgram(rciProbe,rciProbe.o,rciProbeCtrl.o,)
rccUtilityProgram(rciProbe,rciProbe.o,rciProbeCtrl.o,)
ctrlModule(rciProbeCtrl)

vxwBinModule(rciProbe)
vxwBinModule(rciProbeCtrl)

# program to test the device drivers themselves 
rccTestProgram(driverTest,driverTest.o,driverTestCtrl.o,)
ctrlModule(driverTest.real)

rciUserModule(IOdriver)
rciUserModule(IOdriverTable)

rciCtrlModule(driErrorMsgs)
rciCtrlModule(priDriver)
rciCtrlModule(simDriver)
rciCtrlModule(memDriver)
rciCtrlModule(drjDriver)
rciCtrlModule(vemDriver)
#if !VxWorksConfig
rciCtrlModule(xydDriver)
rciCtrlModule(xy2dDriver)
rciCtrlModule(pioDriver)
#else
rciCtrlModuleDep(xydDriver)
rciCtrlModuleDep(xy2dDriver)
rciCtrlModuleDep(pioDriver)
# we compile these explicitly because we can't use FPU in interupt
# level code, and the default CFLAGS has -f68881, which causes this
xydDriver.o:  xydDriver.c
	$(CC) -c $(C_INCS) $(C_DEFS) $<
xy2dDriver.o:  xy2dDriver.c
	$(CC) -c $(C_INCS) $(C_DEFS) $<
pioDriver.o:  pioDriver.c
	$(CC) -c $(C_INCS) $(C_DEFS) $<
#endif
#ifdef LinuxConfig
CFLAGS = $(RCC_CFLAGS) -g -O2
rciCtrlModule(triDriver)
#endif
maintainRciUser(libs)
maintainRciCtrl(libs)
maintainUtils(install)
maintainVxwLibs(vxwDrivers,vxlibs)
maintainVxwBins(vxwRciProbe,vxbins)

makeClean(iotest driverTest rciProbe)
makeDepend()
maintainVxwSubdir()


