If I build a copy of pvaSrv then directories in testTop/iocBoot and exampleTop/iocBoot will contain a file envPaths with environmental variables needed to run the test/examples in these directories.
If I build for two targets, say Linux then Windows, the envPaths from the first build will be overwritten by the one from the second and the examples won't work for the first target.
So if I set
SUPPORT=/dls_sw/prod/R3.14.12.3/support
in RELEASE.linux-x86_64[.*]
and
SUPPORT=W:/prod/R3.14.12.3/support
in RELEASE.windows-64[.*] then the line
epicsEnvSet("PVASRV","/dls_sw/prod/R3.14.12.3/support/pvaSrv/0-10-5/testTop/..")
will be overwritten by
epicsEnvSet("PVASRV","W:/prod/R3.14.12.3/support/pvaSrv/0-10-5/testTop/..")
At Diamond all production software is run from a production area which we only have read-access which we release to through scripts. Therefore if I tag the release and then run scripts (which do a "make") for Linux and then Windows, only the Windows example will work. I can't resolve this after the running the scripts as I don't have write access. This is what happened when I released the 4.4.0 modules.
It would be nice if the examples in our production area actually worked. So I'd like a fix to go into pvaSrv so that the examples all run.
Given we want to deploy 4.5.0.1 I'd also like to apply the patch to the 4.5.0.1.
As we want to start deploying 4.5.0.1 this shutdown (starting March 11) I could do with a fix in the next working day or 2.
I tried coming up with a fix. The following change worked, except that it amake clean in testTop doesn't remove the envPaths.*:
--- a/testTop/iocBoot/testDbPv/Makefile
+++ b/testTop/iocBoot/testDbPv/Makefile
@@ -1,5 +1,7 @@
TOP = ../..
include $(TOP)/configure/CONFIG
ARCH = $(EPICS_HOST_ARCH)
-TARGETS = envPaths
+envPaths.$(EPICS_HOST_ARCH) : envPaths
+ cp envPaths envPaths.$(EPICS_HOST_ARCH)
+TARGETS = envPaths.$(EPICS_HOST_ARCH)
include $(TOP)/configure/RULES.ioc
diff --git a/testTop/iocBoot/testDbPv/st.cmd b/testTop/iocBoot/testDbPv/st.cmd
index 8dd5590..7ab060c 100644
--- a/testTop/iocBoot/testDbPv/st.cmd
+++ b/testTop/iocBoot/testDbPv/st.cmd
@@ -1,4 +1,4 @@
-< envPaths
+< envPaths.${EPICS_HOST_ARCH}
How is this as a fix? Is $(EPICS_HOST_ARCH) the right choice or would a different variable be better. Is there a way of cleaning the envPaths.*s.
I'm sure there are EPICS build experts who can suggest a better fix though.
If I build a copy of pvaSrv then directories in testTop/iocBoot and exampleTop/iocBoot will contain a file envPaths with environmental variables needed to run the test/examples in these directories.
If I build for two targets, say Linux then Windows, the envPaths from the first build will be overwritten by the one from the second and the examples won't work for the first target.
So if I set
SUPPORT=/dls_sw/prod/R3.14.12.3/support
in RELEASE.linux-x86_64[.*]
and
SUPPORT=W:/prod/R3.14.12.3/support
in RELEASE.windows-64[.*] then the line
epicsEnvSet("PVASRV","/dls_sw/prod/R3.14.12.3/support/pvaSrv/0-10-5/testTop/..")
will be overwritten by
epicsEnvSet("PVASRV","W:/prod/R3.14.12.3/support/pvaSrv/0-10-5/testTop/..")
At Diamond all production software is run from a production area which we only have read-access which we release to through scripts. Therefore if I tag the release and then run scripts (which do a "make") for Linux and then Windows, only the Windows example will work. I can't resolve this after the running the scripts as I don't have write access. This is what happened when I released the 4.4.0 modules.
It would be nice if the examples in our production area actually worked. So I'd like a fix to go into pvaSrv so that the examples all run.
Given we want to deploy 4.5.0.1 I'd also like to apply the patch to the 4.5.0.1.
As we want to start deploying 4.5.0.1 this shutdown (starting March 11) I could do with a fix in the next working day or 2.
I tried coming up with a fix. The following change worked, except that it amake clean in testTop doesn't remove the envPaths.*:
--- a/testTop/iocBoot/testDbPv/Makefile +++ b/testTop/iocBoot/testDbPv/Makefile @@ -1,5 +1,7 @@ TOP = ../.. include $(TOP)/configure/CONFIG ARCH = $(EPICS_HOST_ARCH) -TARGETS = envPaths +envPaths.$(EPICS_HOST_ARCH) : envPaths + cp envPaths envPaths.$(EPICS_HOST_ARCH) +TARGETS = envPaths.$(EPICS_HOST_ARCH) include $(TOP)/configure/RULES.ioc diff --git a/testTop/iocBoot/testDbPv/st.cmd b/testTop/iocBoot/testDbPv/st.cmd index 8dd5590..7ab060c 100644 --- a/testTop/iocBoot/testDbPv/st.cmd +++ b/testTop/iocBoot/testDbPv/st.cmd @@ -1,4 +1,4 @@ -< envPaths +< envPaths.${EPICS_HOST_ARCH}How is this as a fix? Is $(EPICS_HOST_ARCH) the right choice or would a different variable be better. Is there a way of cleaning the envPaths.*s.
I'm sure there are EPICS build experts who can suggest a better fix though.