#==============================================================
#
#  Abs:  Makefile to build EPICS Database components
#
#  Name: Makefile
#
#  Facility: LCLS Magnets
#
#  Auth: 16-Aug-2007, Kristi Luchini  (USERNAME)
#  Rev:  dd-mmm-yyyy, First Lastname  (USERNAME)
#--------------------------------------------------------------
#  Mod:
#        01-Mar-2016, K. Luchini      (LUCHINI):
#          remove install of psc-ltu0-mg0<1-5>.db
#          remove install of psc-ltu1-mg0<1-8>.db
#        07-Oct-2015, K. Luchini      (LUCHINI):
#         removed install of ioc-ltu1-mg02.db
#         ioc-ltu1-mg02_poly.db, ioc-ltu1-mg02_emcor.db
#         ioc-ltu1-mg02_epsc.db, psc-ltu1-mg09.db
#         psc-ltu1-mg10.db, psc-ltu1-mg011.db,psc-ltu1-mg12.db
#         plc-ltu1-mg03.db
#         install vioc-ltu1-mg03.db and vioc-ltu1-mg03_emcor.db
#        24-Sep-2015, K. Luchini      (LUCHINI):
#         remove ioc-ltu0-mg01_poly.substitutions
#         and ioc-ltu1-mg01_poly.substitutions,
#         these files are now included in 
#         ioc-ltu0-mg01.substitutions and
#         ioc-ltu1-mg01.substitutions, respectively.
#        20-Sep-2015, K. Luchini      (LUCHINI):
#         remove ioc-ltu0-mg01_func.substitutions
#         remove ioc-ltu1-mg01_func.substitutions
#         remove ioc-ltu1-mg02_func.substitutions
#         these pvs from these dbs are now in
#         Db/all/sioc-sys0-mg01.substitutions
#
#==============================================================
#
TOP=../../..
include $(TOP)/configure/CONFIG
#----------------------------------------
#  ADD MACRO DEFINITIONS AFTER THIS LINE

#----------------------------------------------------
#  Optimization of db files using dbst (DEFAULT: NO)
#DB_OPT = YES

#----------------------------------------------------
# Create and install (or just install) into <top>/db
# databases, templates, substitutions like this
#
# Linac to Undulator
#
# B005
DB += plc-ltu0-mg01.db
DB += plc-ltu1-mg02.db
DB += ioc-ltu0-mg01.db
DB += ioc-ltu0-mg01_mcor.db
DB += ioc-ltu0-mg01_epsc.db
DB += ioc-ltu0-mg01_evr.db
DB += ioc-ltu0-mg01_trig.db
DB += ioc-ltu0-mg01_pau.db

# B911
DB += plc-ltu1-mg01.db
DB += ioc-ltu1-mg01.db
DB += ioc-ltu1-mg01_mcor.db
DB += ioc-ltu1-mg01_epsc.db
DB += ioc-ltu1-mg01_pau.db

# B912
# Note: Order of files in file is important.
# This must be the last db installed
DB += vioc-ltu1-mg03_emcor.db
DB += vioc-ltu1-mg03.db

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


gen_trig_edl:
	create_edm_event_msi.py ioc-ltu0-mg01_trig.substitutions
