# CONFIG_SITE

# Make any application-specific changes to the EPICS build
#   configuration variables in this file.
#
# Host/target specific settings can be specified in files named
#   CONFIG_SITE.$(EPICS_HOST_ARCH).Common
#   CONFIG_SITE.Common.$(T_A)
#   CONFIG_SITE.$(EPICS_HOST_ARCH).$(T_A)

# CHECK_RELEASE controls the consistency checking of the support
#   applications pointed to by the RELEASE* files.
# Normally CHECK_RELEASE should be set to YES.
# Set CHECK_RELEASE to NO to disable checking completely.
# Set CHECK_RELEASE to WARN to perform consistency checking but
#   continue building anyway if conflicts are found.
CHECK_RELEASE = YES

# Set this when you only want to compile this application
#   for a subset of the cross-compiled target architectures
#   that Base is built for.
#CROSS_COMPILER_TARGET_ARCHS = vxWorks-mpc8540 vxWorks-ppc604_long vxWorks-ppc604_altivec
#CROSS_COMPILER_TARGET_ARCHS = RTEMS-beatnik RTEMS-mvme3100 RTEMS-uC5282 linuxRT-x86

# If you only want to build for the host then uncomment the line below and no cross targets
# will be built.  Remember EPICS will build for the HOST ARCH by default.
CROSS_COMPILER_TARGET_ARCHS =  rhel-x86_64
CROSS_COMPILER_TARGET_ARCHS =  linuxRT-x86_64
BUILD_FOR_HOST_ARCH=""

# To install files into a location other than $(TOP) define
#   INSTALL_LOCATION here.
#INSTALL_LOCATION=</path/name/to/install/top>

# Set this when your IOC and the host use different paths
#   to access the application. This will be needed to boot
#   from a Microsoft FTP server or with some NFS mounts.
# You must rebuild in the iocBoot directory for this to
#   take effect.
#IOCS_APPL_TOP = </IOC/path/to/application/top>
IOCS_APPL_TOP  = $(INSTALL_LOCATION)

INSTALL_LOCATION_STARTUP += $(INSTALL_LOCATION)/startup
DIRECTORY_TARGETS += $(INSTALL_LOCATION_STARTUP)

## =============================
## Build Application Statically
## =============================
SHARED_LIBRARIES=NO
STATIC_BUILD=YES

# Location of Linux Kernel Modules:
LINUX_KERNEL_MODULES=$(PACKAGE_SITE_TOP)/linuxKernel_Modules

LINUXRT_BUILDROOT_VERSION=buildroot-2016.11.1
LINUX_VERSION=rhel6

# Let's reference some external packages needed by our build:

# =============================================
# Define the version of external  packages needed by this                      
# IOC Application
# =============================================
include $(TOP)/RELEASE_SITE

#=========================================================
# BOOST
#=========================================================
BOOST_PACKAGE_NAME=boost
BOOST_VERSION=1.63.0
BOOST_TOP=$(PACKAGE_SITE_TOP)/$(BOOST_PACKAGE_NAME)/$(BOOST_VERSION)
BOOST_LIB = $(BOOST_TOP)/$(PKG_ARCH)/lib
BOOST_INCLUDE = $(BOOST_TOP)/$(PKG_ARCH)/include

#=========================================================
# EasyLogging++
#=========================================================
EASYLOGGING=$(PACKAGE_SITE_TOP)/easylogging/easyloggingpp-8.91
EASYLOGGINGPP_INCLUDE = $(EASYLOGGING)

#=========================================================
# Central Node Engine
#=========================================================
CENTRAL_NODE_ENGINE_NAME=central_node_engine
CENTRAL_NODE_ENGINE_VERSION=central_node_engine-R1-3-1
CENTRAL_NODE_ENGINE_TOP=$(PACKAGE_TOP)/$(CENTRAL_NODE_ENGINE_NAME)/$(CENTRAL_NODE_ENGINE_VERSION)
#CENTRAL_NODE_ENGINE_TOP=/afs/slac/u/cd/lpiccoli/top/$(CENTRAL_NODE_ENGINE_NAME)
CENTRAL_NODE_ENGINE_LIB=$(CENTRAL_NODE_ENGINE_TOP)/$(PKG_ARCH)/lib
CENTRAL_NODE_ENGINE_INCLUDE=$(CENTRAL_NODE_ENGINE_TOP)/$(PKG_ARCH)/include

#=========================================================
# YAML-CPP
#=========================================================
YAML_PACKAGE_NAME=yaml-cpp
YAML_VERSION=yaml-cpp-0.5.3
YAML_TOP=$(PACKAGE_SITE_TOP)/$(YAML_PACKAGE_NAME)/$(YAML_VERSION)
YAML_LIB= $(YAML_TOP)/$(PKG_ARCH)/lib
YAML_INCLUDE=$(YAML_TOP)/$(PKG_ARCH)/include

#=========================================================
# CPSW
#=========================================================
CPSW_FRAMEWORK_PACKAGE_NAME=cpsw/framework
CPSW_FRAMEWORK_VERSION=R3.6.4
CPSW_FRAMEWORK_TOP=$(PACKAGE_SITE_TOP)/$(CPSW_FRAMEWORK_PACKAGE_NAME)/$(CPSW_FRAMEWORK_VERSION)
CPSW_FRAMEWORK_LIB = $(CPSW_FRAMEWORK_TOP)/$(PKG_ARCH)/lib
CPSW_FRAMEWORK_INCLUDE = $(CPSW_FRAMEWORK_TOP)/$(PKG_ARCH)/include
