Add module version numbering
This commit is contained in:
14
configure/CONFIG_PCAS_VERSION
Normal file
14
configure/CONFIG_PCAS_VERSION
Normal file
@@ -0,0 +1,14 @@
|
||||
EPICS_PCAS_MAJOR_VERSION = 4
|
||||
EPICS_PCAS_MINOR_VERSION = 13
|
||||
EPICS_PCAS_MAINTENANCE_VERSION = 0
|
||||
EPICS_PCAS_DEVELOPMENT_FLAG = 1
|
||||
|
||||
EXPANDVARS += EPICS_PCAS_MAJOR_VERSION
|
||||
EXPANDVARS += EPICS_PCAS_MINOR_VERSION
|
||||
EXPANDVARS += EPICS_PCAS_MAINTENANCE_VERSION
|
||||
EXPANDVARS += EPICS_PCAS_DEVELOPMENT_FLAG
|
||||
|
||||
EXPANDFLAGS += $(foreach var,$(EXPANDVARS),-D$(var)="$(strip $($(var)))")
|
||||
|
||||
# shared library ABI version.
|
||||
SHRLIB_VERSION = $(EPICS_PCAS_MAJOR_VERSION).$(EPICS_PCAS_MINOR_VERSION)
|
||||
@@ -11,6 +11,8 @@ TOP=../..
|
||||
|
||||
include $(TOP)/configure/CONFIG
|
||||
|
||||
include $(TOP)/configure/CONFIG_PCAS_VERSION
|
||||
|
||||
INC += gdd.h
|
||||
INC += gddI.h
|
||||
INC += gddContainer.h
|
||||
|
||||
@@ -19,11 +19,15 @@ SRC_DIRS += $(SRC)
|
||||
SRC_DIRS += $(IOSRC)
|
||||
SRC_DIRS += $(STSRC)
|
||||
|
||||
include $(TOP)/configure/CONFIG_PCAS_VERSION
|
||||
|
||||
#USR_CXXFLAGS = $(USR_CFLAGS)
|
||||
|
||||
INC += casdef.h
|
||||
INC += casEventMask.h
|
||||
INC += caNetAddr.h
|
||||
INC += casVersion.h
|
||||
INC += casVersionNum.h
|
||||
|
||||
LIBSRCS += caServer.cc
|
||||
LIBSRCS += caServerI.cc
|
||||
@@ -85,3 +89,8 @@ cas_RCS = cas.rc
|
||||
CLEANS += Templates.DB
|
||||
|
||||
include $(TOP)/configure/RULES
|
||||
|
||||
# Can't use EXPAND as generated headers must appear
|
||||
# in O.Common, but EXPAND emits rules for O.$(T_A)
|
||||
../O.Common/casVersionNum.h: ../casVersionNum.h@
|
||||
$(EXPAND_TOOL) $(EXPANDFLAGS) $($@_EXPANDFLAGS) $< $@
|
||||
|
||||
9
src/pcas/build/casVersionNum.h@
Normal file
9
src/pcas/build/casVersionNum.h@
Normal file
@@ -0,0 +1,9 @@
|
||||
#ifndef CASVERSION_H
|
||||
# error include casVersion.h, not this header
|
||||
#endif
|
||||
#define EPICS_CAS_MAJOR_VERSION @EPICS_PCAS_MAJOR_VERSION@
|
||||
#define EPICS_CAS_MINOR_VERSION @EPICS_PCAS_MINOR_VERSION@
|
||||
#define EPICS_CAS_MAINTENANCE_VERSION @EPICS_PCAS_MAINTENANCE_VERSION@
|
||||
#define EPICS_CAS_DEVELOPMENT_FLAG @EPICS_PCAS_DEVELOPMENT_FLAG@
|
||||
|
||||
#define CAS_VERSION_STRING "PCAS @EPICS_PCAS_MAJOR_VERSION@.@EPICS_PCAS_MINOR_VERSION@.@EPICS_PCAS_MAINTENANCE_VERSION@@EPICS_PCAS_DEVELOPMENT_FLAG@"
|
||||
@@ -5,7 +5,7 @@
|
||||
* Operator of Los Alamos National Laboratory.
|
||||
* EPICS BASE Versions 3.13.7
|
||||
* and higher are distributed subject to a Software License Agreement found
|
||||
* in file LICENSE that is included with this distribution.
|
||||
* in file LICENSE that is included with this distribution.
|
||||
\*************************************************************************/
|
||||
/*
|
||||
* Author Jeffrey O. Hill
|
||||
@@ -16,9 +16,9 @@
|
||||
#include <stdarg.h>
|
||||
#include <stdexcept>
|
||||
|
||||
#include "epicsGuard.h"
|
||||
#include "epicsVersion.h"
|
||||
#include "errlog.h"
|
||||
#include <epicsGuard.h>
|
||||
#include <epicsVersion.h>
|
||||
#include <errlog.h>
|
||||
|
||||
#include "addrList.h"
|
||||
|
||||
@@ -29,11 +29,12 @@
|
||||
#include "beaconAnomalyGovernor.h"
|
||||
#include "casStreamOS.h"
|
||||
#include "casIntfOS.h"
|
||||
#include "casVersion.h"
|
||||
|
||||
// include a version string for POSIX systems
|
||||
static const char pVersionCAS[] =
|
||||
"@(#) " EPICS_VERSION_STRING
|
||||
", CA Portable Server Library ";
|
||||
static const char pVersionCAS[] =
|
||||
"@(#) " CAS_VERSION_STRING " (" EPICS_VERSION_STRING ")"
|
||||
", CA Portable Server Library";
|
||||
|
||||
caServerI::caServerI ( caServer & tool ) :
|
||||
adapter (tool),
|
||||
|
||||
20
src/pcas/generic/casVersion.h
Normal file
20
src/pcas/generic/casVersion.h
Normal file
@@ -0,0 +1,20 @@
|
||||
#ifndef CASVERSION_H
|
||||
#define CASVERSION_H
|
||||
|
||||
#include <epicsVersion.h>
|
||||
|
||||
#ifndef VERSION_INT
|
||||
# define VERSION_INT(V,R,M,P) ( ((V)<<24) | ((R)<<16) | ((M)<<8) | (P))
|
||||
#endif
|
||||
|
||||
/* include generated headers with:
|
||||
* EPICS_CAS_MAJOR_VERSION
|
||||
* EPICS_CAS_MINOR_VERSION
|
||||
* EPICS_CAS_MAINTENANCE_VERSION
|
||||
* EPICS_CAS_DEVELOPMENT_FLAG
|
||||
*/
|
||||
#include <casVersionNum.h>
|
||||
|
||||
#define CAS_VERSION_INT VERSION_INT(EPICS_CAS_MAJOR_VERSION, EPICS_CAS_MINOR_VERSION, EPICS_CAS_MAINTENANCE_VERSION, 0)
|
||||
|
||||
#endif // CASVERSION_H
|
||||
Reference in New Issue
Block a user