#==============================================================
#
#  Abs:  Makefile to build EPICS IMPS Application
#
#  Name: Makefile
#
#  Facility:  SLAC/LCLS
#
#  Auth: 09-Feb-2007, A. Alarcon          (ALARCON)
#  Rev:  dd-mmm-yyyy, Reviewer's Name     (USERNAME)
#--------------------------------------------------------------
#  Mod:
#        12-Jun2-2007, Arturo Alarcon     (ALARCON):
#          include CONFIG instead of CONFIG-beatnik
#
#==============================================================
#
#
TOP=../..
include $(TOP)/configure/CONFIG
#----------------------------------------
#  ADD MACRO DEFINITIONS AFTER THIS LINE
#=======================================
#
# build an ioc application

PROD_RTEMS = imps
PROD_HOST  = impsSoft

# Compiler flags
USR_CFLAGS_DEFAULT += -DHOST_TEST -g
USR_CFLAGS_RTEMS   += -g -O4

DBD += impsSoft.dbd
impsSoft_DBD += base.dbd
impsSoft_DBD += devIocStats.dbd
impsSoft_DBD += impsSupport.dbd

DBD += imps.dbd
# imps.dbd will be made up from these files:
imps_DBD += base.dbd

#include definitions for any other support applications needed
#imps_DBD += xxx.dbd
imps_DBD += Xy2445.dbd
imps_DBD += Xy2440.dbd
#imps_DBD += drvXy9660.dbd
imps_DBD += drvIpac.dbd
imps_DBD += dbRestore.dbd
imps_DBD += evrSupport.dbd
imps_DBD += devMrfEr.dbd
imps_DBD += iocAdmin.dbd
imps_DBD += sCalcoutRecord.dbd
imps_DBD += impsSupport.dbd

# <name>_registerRecordDeviceDriver.cpp will be created from <name>.dbd
imps_SRCS     += imps_registerRecordDeviceDriver.cpp
impsSoft_SRCS += impsSoft_registerRecordDeviceDriver.cpp
#imps_SRCS += subImps.c
USR_SRCS_DEFAULT += impsMain.cpp 
USR_SRCS_DEFAULT += subImps.c
imps_SRCS_vxWorks += -nil-
imps_SRCS_RTEMS   += -nil-

#The following adds support from base/src/vxWorks
imps_OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary

USR_LIBS += restore
USR_LIBS += devIocStats
USR_LIBS += calc

ifeq ($(OS_CLASS),RTEMS)
#add a definition for each support application used by this application
#imps_LIBS += xxx
imps_LIBS += evrSupport sSubRecord
imps_LIBS += devMrfEr mrfVme64x
#imps_LIBS += Xy9660
imps_LIBS += Xy2445
imps_LIBS += Xy2440
imps_LIBS += Ipac
endif



USR_LIBS += $(EPICS_BASE_IOC_LIBS)

#=======================================
include $(TOP)/configure/RULES
#----------------------------------------
#  ADD RULES AFTER THIS LINE
#========================================
