TOP=../..

include $(TOP)/configure/CONFIG
#----------------------------------------
#  ADD MACRO DEFINITIONS AFTER THIS LINE
#=============================

#==================================================
# Build an IOC support library

LIBRARY_IOC += xxxSupport

# xxxRecord.h will be created from xxxRecord.dbd
DBDINC += xxxRecord
# install devXxxSoft.dbd into <top>/dbd
DBD += xxxSupport.dbd

# The following are compiled and added to the Support library
xxxSupport_SRCS += xxxRecord.c
xxxSupport_SRCS += devXxxSoft.c

xxxSupport_LIBS += $(EPICS_BASE_IOC_LIBS)

#=============================
# build an ioc application

PROD_IOC = Test
# Test.dbd will be created and installed
DBD += Test.dbd

# Test.dbd will be made up from these files:
Test_DBD += base.dbd
Test_DBD += xxxSupport.dbd
Test_DBD += dbSubExample.dbd
Test_DBD += TestHello.dbd

# <name>_registerRecordDeviceDriver.cpp will be created from <name>.dbd
Test_SRCS += Test_registerRecordDeviceDriver.cpp
Test_SRCS_DEFAULT += TestMain.cpp
Test_SRCS_vxWorks += -nil-

# Add locally compiled object code
Test_SRCS += dbSubExample.c
Test_SRCS += TestHello.c

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

Test_LIBS += xxxSupport
TEST_LIBS += restore iocAdmin


# NOTE: To build SNL programs, SNCSEQ must be defined
# in the <top>/configure/RELEASE file

ifneq ($(SNCSEQ),)
    # This builds sncExample as a component of Test
    Test_SNCFLAGS += +r
    Test_DBD += sncExample.dbd
    Test_SRCS += sncExample.stt
    Test_LIBS += seq pv
    Test_DBD += countAlarms.dbd
    Test_SRCS += countAlarms.stt
#    Test_LIBS += seq pv

    # The following builds sncProgram as a standalone application
#    PROD_HOST += sncProgram
#    sncProgram_SNCFLAGS += +m
#    sncProgram_SRCS += sncProgram.st
#    sncProgram_LIBS += seq pv
#    sncProgram_LIBS += $(EPICS_BASE_HOST_LIBS)
endif

Test_LIBS += $(EPICS_BASE_IOC_LIBS)

#===========================

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

