diff --git a/Makefile b/Makefile index 247c705..7fef527 100644 --- a/Makefile +++ b/Makefile @@ -1,24 +1,17 @@ TOP = .. -DIRS = src -streamApp_DEPEND_DIRS = src - -# Look if we have EPICS R3.13 or R3.14 +# Look if we have EPICS R3.13 or R3.14+ ifeq ($(wildcard $(TOP)/configure),) # EPICS R3.13 include $(TOP)/config/CONFIG_APP CONFIG = $(TOP)/config else - # EPICS R3.14 + # EPICS R3.14+ include $(TOP)/configure/CONFIG - ifneq ($(words $(CALC) $(SYNAPPS)), 0) - # with synApps calc module (contains scalcout) - DIRS += srcSynApps - srcSynApps_DEPEND_DIRS = src - streamApp_DEPEND_DIRS += srcSynApps - endif endif +DIRS += src DIRS += streamApp +streamApp_DEPEND_DIRS = src include $(CONFIG)/RULES_DIRS diff --git a/src/CONFIG_STREAM b/src/CONFIG_STREAM index d6e984e..564480a 100644 --- a/src/CONFIG_STREAM +++ b/src/CONFIG_STREAM @@ -1,6 +1,3 @@ -# Want debugging? -# HOST_OPT = NO - # You may add more record interfaces # This requires the naming conventions # dev$(RECORD)Stream.c @@ -18,12 +15,13 @@ RECORDS += aai aao # Do you have synApps and want support for scalcout? # Then define CALC or SYNAPPS in your RELEASE file # pointing to the 'calc' module of synApps. -# Due to strange cross dependencies in synApps -# you have to build the 'sscan' and 'genSub' -# modules before building 'calc'. +# Older 'calc' versions have a cross reference on +# 'sscan' and/or 'genSub', so you may have to build them first. # See doc/scalcout.html for a required fix in scalcout. -SYNAPPS_RECORDS += scalcout +ifneq ($(words $(CALC) $(SYNAPPS)),0) +RECORDS += scalcout +endif # You may add more bus interfaces # This requires the naming convention @@ -33,6 +31,9 @@ SYNAPPS_RECORDS += scalcout BUSSES += Debug BUSSES += Dummy +ifdef ASYN +BUSSES += AsynDriver +endif # You may add more format converters # This requires the naming convention diff --git a/src/Makefile b/src/Makefile index ed146e0..30bf5a4 100644 --- a/src/Makefile +++ b/src/Makefile @@ -20,7 +20,7 @@ TOP=../.. -# Look if we have EPICS R3.13 or R3.14 +# Look if we have EPICS R3.13 or R3.14+ ifeq ($(wildcard $(TOP)/configure),) # EPICS R3.13 include $(TOP)/config/CONFIG_APP @@ -40,13 +40,8 @@ DBD += $(LIBRARY_DEFAULT).dbd ifdef ASYN LIB_LIBS += asyn -BUSSES += AsynDriver -endif - -ifdef T_A -ifndef BUSSES -$(error No bus interface defined! Didn't you set ASYN in your RELEASE file?) -endif +else +$(Warning AsynDriver interface not included! Didn't you set ASYN in your RELEASE file?) endif ifeq ($(LOADABLE_MODULE),YES) diff --git a/src/Makefile.Vx b/src/Makefile.Vx index e95ce60..c401088 100644 --- a/src/Makefile.Vx +++ b/src/Makefile.Vx @@ -28,10 +28,6 @@ LIBNAME = streamLib # In 3.13, calcout has no device support RECORDS_3_13 = $(filter-out calcout,$(RECORDS)) -ifdef ASYN -BUSSES += AsynDriver -endif - SRCS.cc += $(patsubst %,../%,$(filter %.cc,$(STREAM_SRCS))) SRCS.cc += $(BUSSES:%=../%Interface.cc) SRCS.cc += $(FORMATS:%=../%Converter.cc) diff --git a/srcSynApps/devscalcoutStream.c b/src/devscalcoutStream.c similarity index 96% rename from srcSynApps/devscalcoutStream.c rename to src/devscalcoutStream.c index 21b397f..e84f8aa 100644 --- a/srcSynApps/devscalcoutStream.c +++ b/src/devscalcoutStream.c @@ -21,14 +21,14 @@ #include "epicsExport.h" #include "devStream.h" -/* scalcout record has a bug: it never calls init_record +/* Up to version 2-6-1 of the SynApps calc module + scalcout record has a bug: it never calls init_record of the device support. Fix: sCalcoutRecord.c, end of init_record() add if(pscalcoutDSET->init_record ) { return (*pscalcoutDSET->init_record)(pcalc); } - The bug has been fixed in version 2-6-1. */ static long readData (dbCommon *record, format_t *format) diff --git a/srcSynApps/Makefile b/srcSynApps/Makefile deleted file mode 100644 index 4fec9f9..0000000 --- a/srcSynApps/Makefile +++ /dev/null @@ -1,23 +0,0 @@ -TOP=../.. - -include $(TOP)/configure/CONFIG - --include ../src/CONFIG_STREAM --include ../../src/CONFIG_STREAM - -LIBRARY_DEFAULT = streamSynApps - -DBD += $(LIBRARY_DEFAULT).dbd - -ifeq ($(LOADABLE_MODULE),YES) -SRCS += $(LIBRARY_DEFAULT)_registerRecordDeviceDriver.cpp -endif -SRCS += $(SYNAPPS_RECORDS:%=dev%Stream.c) - -LIB_LIBS += stream $(EPICS_BASE_IOC_LIBS) - -include $(TOP)/configure/RULES - -# create streamSynApps.dbd from all SYNAPPS_RECORDS -$(COMMON_DIR)/$(LIBRARY_DEFAULT).dbd: ../../src/CONFIG_STREAM - $(PERL) ../../src/makedbd.pl $(SYNAPPS_RECORDS) > $@ diff --git a/streamApp/Makefile b/streamApp/Makefile index 1981c42..2a72ec4 100644 --- a/streamApp/Makefile +++ b/streamApp/Makefile @@ -1,6 +1,6 @@ TOP=../.. -# Look if we have EPICS R3.13 or R3.14 +# Look if we have EPICS R3.13 or R3.14+ ifeq ($(wildcard $(TOP)/configure),) # EPICS R3.13 include $(TOP)/config/CONFIG_APP @@ -8,11 +8,9 @@ include $(TOP)/config/CONFIG_APP include $(TOP)/config/RULES_ARCHS else -# EPICS R3.14 +# EPICS R3.14+ include $(TOP)/configure/CONFIG -#HOST_OPT = NO - PROD = streamApp DBD = streamApp.dbd @@ -41,11 +39,11 @@ endif ifneq ($(words $(CALC) $(SYNAPPS)), 0) # With synApps scalcout record streamApp_DBD += calcSupport.dbd -streamApp_DBD += streamSynApps.dbd PROD_LIBS += calc # older calc versions require sscan -#PROD_LIBS += sscan -PROD_LIBS_DEFAULT += streamSynApps +ifneq ($(words $(SSCAN) $(SYNAPPS)), 0) +PROD_LIBS += sscan +endif endif streamApp_DBD += stream.dbd