From 28a8c06075a1cdaa85d97114acff14d1b5bd42ee Mon Sep 17 00:00:00 2001 From: Andrew Johnson Date: Thu, 7 Dec 2017 18:01:09 -0600 Subject: [PATCH] Set EPICS_HOST_ARCH in the environment, not just locally This is essential for submodules, which now need that value to load the right modules/RELEASE..local file which gives them their path to EPICS_BASE (they can't set it for themselves without knowing that path because the startup directory is part of core!). --- configure/CONFIG | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/configure/CONFIG b/configure/CONFIG index 580b58767..435ff9e77 100644 --- a/configure/CONFIG +++ b/configure/CONFIG @@ -20,11 +20,12 @@ else endif # Provide a default if the user hasn't set EPICS_HOST_ARCH -ifeq ($(origin EPICS_HOST_ARCH), undefined) - # NB: We use a simply expanded variable here for performance: - EPICS_HOST_ARCH := $(shell $(CONFIG)/../startup/EpicsHostArch.pl) +ifeq ($(strip $(EPICS_HOST_ARCH)),) + # NB: We must set the environment variable for submodules to include + # the correct modules/RELEASE..local file to set EPICS_BASE, + # they can't do this for themselves since CONFIG is relative to it: + export EPICS_HOST_ARCH := $(shell $(CONFIG)/../startup/EpicsHostArch.pl) endif -# -include $(CONFIG)/RELEASE -include $(CONFIG)/RELEASE.$(EPICS_HOST_ARCH)