# CONFIG - Load build configuration data
#
# Do not make changes to this file!

# Allow user to override where the build rules come from
RULES = $(EPICS_BASE)

# RELEASE files point to other application tops
include $(TOP)/configure/RELEASE
-include $(TOP)/configure/RELEASE.$(EPICS_HOST_ARCH).Common
ifdef T_A
-include $(TOP)/configure/RELEASE.Common.$(T_A)
-include $(TOP)/configure/RELEASE.$(EPICS_HOST_ARCH).$(T_A)
endif

CONFIG = $(RULES)/configure
include $(CONFIG)/CONFIG

# Override the Base definition:
INSTALL_LOCATION = $(TOP)

# CONFIG_SITE files contain other build configuration settings
include $(TOP)/configure/CONFIG_SITE
-include $(TOP)/configure/CONFIG_SITE.$(EPICS_HOST_ARCH).Common
ifdef T_A
 -include $(TOP)/configure/CONFIG_SITE.Common.$(T_A)
 -include $(TOP)/configure/CONFIG_SITE.$(EPICS_HOST_ARCH).$(T_A)
endif

# Test for required *_LIB and *_INCLUDE directories
ifdef T_A
ifeq ($(wildcard $(CPSW_FRAMEWORK_LIB)/*),)
$(error CPSW_FRAMEWORK_LIB Not found: $(CPSW_FRAMEWORK_LIB))
endif
ifeq ($(wildcard $(CPSW_FRAMEWORK_INCLUDE)/*),)
$(error CPSW_FRAMEWORK_INCLUDE Not found: $(CPSW_FRAMEWORK_INCLUDE))
endif
ifeq ($(wildcard $(YAML_LIB)/*),)
$(error YAML_LIB Not found: $$(YAML_LIB))
endif
ifeq ($(wildcard $(YAML_INCLUDE)/*),)
$(error YAML_INCLUDE Not found: $$(YAML_INCLUDE))
endif
ifeq ($(wildcard $(BOOST_LIB)/*),)
$(error BOOST_LIB Not found: $$(BOOST_LIB))
endif
ifeq ($(wildcard $(BOOST_INCLUDE)/*),)
$(error BOOST_INCLUDE Not found: $$(BOOST_INCLUDE))
endif
ifeq ($(wildcard $(HPSTPR_LIB)/*),)
$(error HPSTPR_LIB Not found: $$(HPSTPR_LIB))
endif
ifeq ($(wildcard $(HPSTPR_INCLUDE)/*),)
$(error HPSTPR_INCLUDE Not found: $$(HPSTPR_INCLUDE))
endif
endif
