diff --git a/src/libCom/assertVX.c b/src/libCom/assertVX.c index 6e0cd1be9..f69134c46 100644 --- a/src/libCom/assertVX.c +++ b/src/libCom/assertVX.c @@ -27,6 +27,9 @@ * Modification Log: * ----------------- * $Log$ + * Revision 1.8 1997/05/01 19:57:10 jhill + * updated dll keywords + * * Revision 1.7 1997/04/10 19:45:16 jhill * API changes and include with not <> * @@ -53,11 +56,13 @@ #include #include -#define epicsExportSharedSymbols -#include "epicsAssert.h" #include "epicsPrint.h" #include "epicsVersion.h" +#define epicsExportSharedSymbols +#include "epicsAssert.h" + + /* * epicsAssert () diff --git a/src/libCom/bucketLib.c b/src/libCom/bucketLib.c index 5fa2c8778..ea56bb0e5 100644 --- a/src/libCom/bucketLib.c +++ b/src/libCom/bucketLib.c @@ -41,9 +41,13 @@ #include #include -#define epicsExportSharedSymbols #include "epicsAssert.h" #include "freeList.h" /* bucketLib uses freeListLib inside the DLL */ + +#ifdef INCbucketLibh +#error bucketLib.h has been included too soon +#endif +#define epicsExportSharedSymbols #include "bucketLib.h" #ifndef TRUE diff --git a/src/libCom/bucketLib.h b/src/libCom/bucketLib.h index 560a7e2d3..4d7c5a877 100644 --- a/src/libCom/bucketLib.h +++ b/src/libCom/bucketLib.h @@ -33,6 +33,9 @@ * .02 121693 joh added bucketFree() * .03 052395 joh use std EPICS status * $Log$ + * Revision 1.5 1997/05/01 19:57:13 jhill + * updated dll keywords + * * Revision 1.4 1997/04/29 06:17:18 jhill * use free lists * @@ -52,10 +55,21 @@ #ifdef __cplusplus extern "C" { +#endif + + /* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport #endif #include "errMdef.h" #include "epicsTypes.h" + +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif #include "shareLib.h" typedef unsigned BUCKETID; diff --git a/src/libCom/bucketLib/bucketLib.c b/src/libCom/bucketLib/bucketLib.c index 5fa2c8778..ea56bb0e5 100644 --- a/src/libCom/bucketLib/bucketLib.c +++ b/src/libCom/bucketLib/bucketLib.c @@ -41,9 +41,13 @@ #include #include -#define epicsExportSharedSymbols #include "epicsAssert.h" #include "freeList.h" /* bucketLib uses freeListLib inside the DLL */ + +#ifdef INCbucketLibh +#error bucketLib.h has been included too soon +#endif +#define epicsExportSharedSymbols #include "bucketLib.h" #ifndef TRUE diff --git a/src/libCom/bucketLib/bucketLib.h b/src/libCom/bucketLib/bucketLib.h index 560a7e2d3..4d7c5a877 100644 --- a/src/libCom/bucketLib/bucketLib.h +++ b/src/libCom/bucketLib/bucketLib.h @@ -33,6 +33,9 @@ * .02 121693 joh added bucketFree() * .03 052395 joh use std EPICS status * $Log$ + * Revision 1.5 1997/05/01 19:57:13 jhill + * updated dll keywords + * * Revision 1.4 1997/04/29 06:17:18 jhill * use free lists * @@ -52,10 +55,21 @@ #ifdef __cplusplus extern "C" { +#endif + + /* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport #endif #include "errMdef.h" #include "epicsTypes.h" + +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif #include "shareLib.h" typedef unsigned BUCKETID; diff --git a/src/libCom/calc/calcPerform.c b/src/libCom/calc/calcPerform.c index 8e7cdfd6e..9c8c0ffc8 100644 --- a/src/libCom/calc/calcPerform.c +++ b/src/libCom/calc/calcPerform.c @@ -109,10 +109,12 @@ #include #include -#define epicsExportSharedSymbols #include "dbDefs.h" #include "postfix.h" +#define epicsExportSharedSymbols +#include "shareLib.h" + static double local_random(); #define NOT_SET 0 diff --git a/src/libCom/calc/postfix.c b/src/libCom/calc/postfix.c index 9eb418d26..ef5ce991f 100644 --- a/src/libCom/calc/postfix.c +++ b/src/libCom/calc/postfix.c @@ -98,8 +98,12 @@ #include #include -#define epicsExportSharedSymbols #include "dbDefs.h" + +#ifdef INCpostfixh +#error postfix.h has been included too soon +#endif +#define epicsExportSharedSymbols #include "postfix.h" diff --git a/src/libCom/calc/postfix.h b/src/libCom/calc/postfix.h index c933d2b34..5f7193933 100644 --- a/src/libCom/calc/postfix.h +++ b/src/libCom/calc/postfix.h @@ -37,6 +37,8 @@ #ifndef INCpostfixh #define INCpostfixh +#include + /* defines for element table */ #define BAD_EXPRESSION 0 #define FETCH_A 1 diff --git a/src/libCom/calcPerform.c b/src/libCom/calcPerform.c index 8e7cdfd6e..9c8c0ffc8 100644 --- a/src/libCom/calcPerform.c +++ b/src/libCom/calcPerform.c @@ -109,10 +109,12 @@ #include #include -#define epicsExportSharedSymbols #include "dbDefs.h" #include "postfix.h" +#define epicsExportSharedSymbols +#include "shareLib.h" + static double local_random(); #define NOT_SET 0 diff --git a/src/libCom/errSymLib.c b/src/libCom/errSymLib.c index e9451ba15..6d854d637 100644 --- a/src/libCom/errSymLib.c +++ b/src/libCom/errSymLib.c @@ -70,7 +70,6 @@ #include #include -#define epicsExportSharedSymbols #include "ellLib.h" #include "dbDefs.h" #include "errMdef.h" @@ -83,6 +82,9 @@ #include #include +#define epicsExportSharedSymbols +#include "shareLib.h" + extern SYMTAB_ID statSymTbl; #endif diff --git a/src/libCom/errlog.h b/src/libCom/errlog.h index 1232386db..079514c7d 100644 --- a/src/libCom/errlog.h +++ b/src/libCom/errlog.h @@ -15,6 +15,8 @@ of this distribution. #include +#include + #ifdef __cplusplus extern "C" { #define epicsPrintUseProtoANSI @@ -36,20 +38,20 @@ extern "C" { typedef void(*errlogListener) (const char *message); typedef enum {errlogInfo,errlogMinor,errlogMajor,errlogFatal} errlogSevEnum; -extern char * errlogSevEnumString[]; -#ifdef ERRLOG_INIT -char * errlogSevEnumString[] = {"info","minor","major","fatal"}; +epicsShareExtern char * errlogSevEnumString[]; +#ifdef epicsExportSharedSymbols +epicsShareDef char * errlogSevEnumString[] = {"info","minor","major","fatal"}; #endif #ifdef epicsPrintUseProtoANSI -epicsShareFunc int epicsShareAPI errlogPrintf( +epicsShareFunc int epicsShareAPIV errlogPrintf( const char *pformat, ...); -epicsShareFunc int epicsShareAPI errlogVprintf( +epicsShareFunc int epicsShareAPIV errlogVprintf( const char *pformat,va_list pvar); -epicsShareFunc int epicsShareAPI errlogSevPrintf( +epicsShareFunc int epicsShareAPIV errlogSevPrintf( const errlogSevEnum severity,const char *pformat, ...); -epicsShareFunc int epicsShareAPI errlogSevVprintf( +epicsShareFunc int epicsShareAPIV errlogSevVprintf( const errlogSevEnum severity,const char *pformat,va_list pvar); epicsShareFunc int epicsShareAPI errlogMessage( const char *message); @@ -69,7 +71,7 @@ epicsShareFunc void epicsShareAPI eltc(int yesno); epicsShareFunc void epicsShareAPI errlogInit(int bufsize); /*other routines that write to log file*/ -epicsShareFunc void epicsShareAPI errPrintf(long status, const char *pFileName, +epicsShareFunc void epicsShareAPIV errPrintf(long status, const char *pFileName, int lineno, const char *pformat, ...); #else /* not epicsPrintUseProtoANSI */ diff --git a/src/libCom/errlogUNIX.c b/src/libCom/errlogUNIX.c index 469d06761..abec101b0 100644 --- a/src/libCom/errlogUNIX.c +++ b/src/libCom/errlogUNIX.c @@ -56,20 +56,17 @@ * (Appropriate for what we implenment) */ #define epicsExportSharedSymbols -#include /* Include errlog.h here (by undefining INCerrlogh) to: * (1) Make the declarations be export - * (2) Allocate storage (Controlled by ERRLOG_INIT) + * (2) Allocate storage for errlogSevEnumString[] */ #undef INCerrlogh -#define ERRLOG_INIT #include "errlog.h" -#undef ERRLOG_INIT static int sevToLog=0; -epicsShareFunc int epicsShareAPI errlogPrintf(const char *pformat, ...) +epicsShareFunc int epicsShareAPIV errlogPrintf(const char *pformat, ...) { va_list pvar; int nchar; @@ -80,7 +77,7 @@ epicsShareFunc int epicsShareAPI errlogPrintf(const char *pformat, ...) return(nchar); } -epicsShareFunc int epicsShareAPI errlogVprintf( +epicsShareFunc int epicsShareAPIV errlogVprintf( const char *pformat, va_list pvar) { return(vfprintf(stderr,pformat,pvar)); @@ -92,7 +89,7 @@ epicsShareFunc int epicsShareAPI errlogMessage(const char *message) return(0); } -epicsShareFunc int epicsShareAPI errlogSevPrintf( +epicsShareFunc int epicsShareAPIV errlogSevPrintf( const errlogSevEnum severity,const char *pformat, ...) { va_list pvar; @@ -105,7 +102,7 @@ epicsShareFunc int epicsShareAPI errlogSevPrintf( return(nchar); } -epicsShareFunc int epicsShareAPI errlogSevVprintf( +epicsShareFunc int epicsShareAPIV errlogSevVprintf( const errlogSevEnum severity,const char *pformat,va_list pvar) { char *pnext; @@ -155,7 +152,7 @@ epicsShareFunc void epicsShareAPI errlogRemoveListener( } -epicsShareFunc void epicsShareAPI errPrintf(long status, const char *pFileName, +epicsShareFunc void epicsShareAPIV errPrintf(long status, const char *pFileName, int lineno, const char *pformat, ...) { va_list pvar; diff --git a/src/libCom/errlogVX.c b/src/libCom/errlogVX.c index 7ae187b3f..fc0f340ae 100644 --- a/src/libCom/errlogVX.c +++ b/src/libCom/errlogVX.c @@ -28,15 +28,30 @@ of this distribution. #include #include "epicsAssert.h" -#define epicsExportSharedSymbols -#define ERRLOG_INIT -#include "errlog.h" -#undef ERRLOG_INIT -#undef epicsExportSharedSymbols +/* errlog.h is included in errMdef.h for historical reasons + * We want to include errMdef.h here but not errlog.h + * (If we include it here, the epicsShareThings will be declared as import) + * (Is only a problem for WIN32 but done here for consistency) + * Define INCerrlog to keep it from being included + */ +#define INCerrlogh #include "errMdef.h" -#include "ellLib.h" #include "error.h" +#include "ellLib.h" #include "task_params.h" +/* Up to now epicsShareThings have been declared as imports + * (Appropriate for other stuff) + * After setting the following they will be declared as exports + * (Appropriate for what we implenment) + */ +#define epicsExportSharedSymbols +/* Include errlog.h here (by undefining INCerrlogh) to: + * (1) Make the declarations be export + * (2) Allocate storage for errlogSevEnumString[] + */ +#undef INCerrlogh +#include "errlog.h" + #ifndef LOCAL #define LOCAL static @@ -83,7 +98,7 @@ LOCAL struct { void *pbuffer; }pvtData; -epicsShareFunc int epicsShareAPI errlogPrintf( const char *pFormat, ...) +epicsShareFunc int epicsShareAPIV errlogPrintf( const char *pFormat, ...) { va_list pvar; int nchar; @@ -99,7 +114,7 @@ epicsShareFunc int epicsShareAPI errlogPrintf( const char *pFormat, ...) return(nchar); } -epicsShareFunc int epicsShareAPI errlogVprintf( +epicsShareFunc int epicsShareAPIV errlogVprintf( const char *pFormat,va_list pvar) { int nchar; @@ -135,7 +150,7 @@ epicsShareFunc int epicsShareAPI errlogMessage(const char *message) return 0; } -epicsShareFunc int epicsShareAPI errlogSevPrintf( +epicsShareFunc int epicsShareAPIV errlogSevPrintf( const errlogSevEnum severity,const char *pFormat, ...) { va_list pvar; @@ -153,7 +168,7 @@ epicsShareFunc int epicsShareAPI errlogSevPrintf( return(nchar); } -epicsShareFunc int epicsShareAPI errlogSevVprintf( +epicsShareFunc int epicsShareAPIV errlogSevVprintf( const errlogSevEnum severity,const char *pFormat,va_list pvar) { char *pnext; @@ -240,7 +255,7 @@ epicsShareFunc void epicsShareAPI eltc(int yesno) pvtData.toConsole = yesno; } -epicsShareFunc void epicsShareAPI errPrintf(long status, const char *pFileName, +epicsShareFunc void epicsShareAPIV errPrintf(long status, const char *pFileName, int lineno, const char *pformat, ...) { va_list pvar; diff --git a/src/libCom/error/errSymLib.c b/src/libCom/error/errSymLib.c index e9451ba15..6d854d637 100644 --- a/src/libCom/error/errSymLib.c +++ b/src/libCom/error/errSymLib.c @@ -70,7 +70,6 @@ #include #include -#define epicsExportSharedSymbols #include "ellLib.h" #include "dbDefs.h" #include "errMdef.h" @@ -83,6 +82,9 @@ #include #include +#define epicsExportSharedSymbols +#include "shareLib.h" + extern SYMTAB_ID statSymTbl; #endif diff --git a/src/libCom/error/errlog.c b/src/libCom/error/errlog.c index 7ae187b3f..fc0f340ae 100644 --- a/src/libCom/error/errlog.c +++ b/src/libCom/error/errlog.c @@ -28,15 +28,30 @@ of this distribution. #include #include "epicsAssert.h" -#define epicsExportSharedSymbols -#define ERRLOG_INIT -#include "errlog.h" -#undef ERRLOG_INIT -#undef epicsExportSharedSymbols +/* errlog.h is included in errMdef.h for historical reasons + * We want to include errMdef.h here but not errlog.h + * (If we include it here, the epicsShareThings will be declared as import) + * (Is only a problem for WIN32 but done here for consistency) + * Define INCerrlog to keep it from being included + */ +#define INCerrlogh #include "errMdef.h" -#include "ellLib.h" #include "error.h" +#include "ellLib.h" #include "task_params.h" +/* Up to now epicsShareThings have been declared as imports + * (Appropriate for other stuff) + * After setting the following they will be declared as exports + * (Appropriate for what we implenment) + */ +#define epicsExportSharedSymbols +/* Include errlog.h here (by undefining INCerrlogh) to: + * (1) Make the declarations be export + * (2) Allocate storage for errlogSevEnumString[] + */ +#undef INCerrlogh +#include "errlog.h" + #ifndef LOCAL #define LOCAL static @@ -83,7 +98,7 @@ LOCAL struct { void *pbuffer; }pvtData; -epicsShareFunc int epicsShareAPI errlogPrintf( const char *pFormat, ...) +epicsShareFunc int epicsShareAPIV errlogPrintf( const char *pFormat, ...) { va_list pvar; int nchar; @@ -99,7 +114,7 @@ epicsShareFunc int epicsShareAPI errlogPrintf( const char *pFormat, ...) return(nchar); } -epicsShareFunc int epicsShareAPI errlogVprintf( +epicsShareFunc int epicsShareAPIV errlogVprintf( const char *pFormat,va_list pvar) { int nchar; @@ -135,7 +150,7 @@ epicsShareFunc int epicsShareAPI errlogMessage(const char *message) return 0; } -epicsShareFunc int epicsShareAPI errlogSevPrintf( +epicsShareFunc int epicsShareAPIV errlogSevPrintf( const errlogSevEnum severity,const char *pFormat, ...) { va_list pvar; @@ -153,7 +168,7 @@ epicsShareFunc int epicsShareAPI errlogSevPrintf( return(nchar); } -epicsShareFunc int epicsShareAPI errlogSevVprintf( +epicsShareFunc int epicsShareAPIV errlogSevVprintf( const errlogSevEnum severity,const char *pFormat,va_list pvar) { char *pnext; @@ -240,7 +255,7 @@ epicsShareFunc void epicsShareAPI eltc(int yesno) pvtData.toConsole = yesno; } -epicsShareFunc void epicsShareAPI errPrintf(long status, const char *pFileName, +epicsShareFunc void epicsShareAPIV errPrintf(long status, const char *pFileName, int lineno, const char *pformat, ...) { va_list pvar; diff --git a/src/libCom/error/errlog.h b/src/libCom/error/errlog.h index 1232386db..079514c7d 100644 --- a/src/libCom/error/errlog.h +++ b/src/libCom/error/errlog.h @@ -15,6 +15,8 @@ of this distribution. #include +#include + #ifdef __cplusplus extern "C" { #define epicsPrintUseProtoANSI @@ -36,20 +38,20 @@ extern "C" { typedef void(*errlogListener) (const char *message); typedef enum {errlogInfo,errlogMinor,errlogMajor,errlogFatal} errlogSevEnum; -extern char * errlogSevEnumString[]; -#ifdef ERRLOG_INIT -char * errlogSevEnumString[] = {"info","minor","major","fatal"}; +epicsShareExtern char * errlogSevEnumString[]; +#ifdef epicsExportSharedSymbols +epicsShareDef char * errlogSevEnumString[] = {"info","minor","major","fatal"}; #endif #ifdef epicsPrintUseProtoANSI -epicsShareFunc int epicsShareAPI errlogPrintf( +epicsShareFunc int epicsShareAPIV errlogPrintf( const char *pformat, ...); -epicsShareFunc int epicsShareAPI errlogVprintf( +epicsShareFunc int epicsShareAPIV errlogVprintf( const char *pformat,va_list pvar); -epicsShareFunc int epicsShareAPI errlogSevPrintf( +epicsShareFunc int epicsShareAPIV errlogSevPrintf( const errlogSevEnum severity,const char *pformat, ...); -epicsShareFunc int epicsShareAPI errlogSevVprintf( +epicsShareFunc int epicsShareAPIV errlogSevVprintf( const errlogSevEnum severity,const char *pformat,va_list pvar); epicsShareFunc int epicsShareAPI errlogMessage( const char *message); @@ -69,7 +71,7 @@ epicsShareFunc void epicsShareAPI eltc(int yesno); epicsShareFunc void epicsShareAPI errlogInit(int bufsize); /*other routines that write to log file*/ -epicsShareFunc void epicsShareAPI errPrintf(long status, const char *pFileName, +epicsShareFunc void epicsShareAPIV errPrintf(long status, const char *pFileName, int lineno, const char *pformat, ...); #else /* not epicsPrintUseProtoANSI */ diff --git a/src/libCom/fdmgr.c b/src/libCom/fdmgr.c index 395990c0b..05bff1f49 100644 --- a/src/libCom/fdmgr.c +++ b/src/libCom/fdmgr.c @@ -71,6 +71,9 @@ * we eliminate delete ambiguity (chance of the same * being reused). * $Log$ + * Revision 1.27 1998/02/05 21:08:52 jhill + * use SOCK error defs and use priority inheritance mutex + * * Revision 1.26 1997/08/05 00:37:02 jhill * removed warnings * @@ -126,9 +129,13 @@ static char *pSccsId = "@(#) $Id$"; #include #endif -#define epicsExportSharedSymbols #include "epicsAssert.h" #include "epicsTypes.h" + +#ifdef includeFdmgrH +#error fdmgr.h has been included too soon +#endif +#define epicsExportSharedSymbols #include "fdmgr.h" #if 0 diff --git a/src/libCom/fdmgr.h b/src/libCom/fdmgr.h index 81c9596ba..32e2a1f2b 100644 --- a/src/libCom/fdmgr.h +++ b/src/libCom/fdmgr.h @@ -44,13 +44,24 @@ #ifdef __cplusplus extern "C" { +#endif + + /* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport #endif #include "ellLib.h" #include "bucketLib.h" -#include "shareLib.h" #include "osiSock.h" +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif +#include "shareLib.h" + enum fdi_type {fdi_read, fdi_write, fdi_excp}; enum alarm_list_type {alt_invalid, alt_alarm, alt_expired, alt_free}; diff --git a/src/libCom/fdmgr/fdmgr.h b/src/libCom/fdmgr/fdmgr.h index 81c9596ba..32e2a1f2b 100644 --- a/src/libCom/fdmgr/fdmgr.h +++ b/src/libCom/fdmgr/fdmgr.h @@ -44,13 +44,24 @@ #ifdef __cplusplus extern "C" { +#endif + + /* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport #endif #include "ellLib.h" #include "bucketLib.h" -#include "shareLib.h" #include "osiSock.h" +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif +#include "shareLib.h" + enum fdi_type {fdi_read, fdi_write, fdi_excp}; enum alarm_list_type {alt_invalid, alt_alarm, alt_expired, alt_free}; diff --git a/src/libCom/gpHash/gpHashLib.c b/src/libCom/gpHash/gpHashLib.c index 2694ef39d..4b3cbd2b0 100644 --- a/src/libCom/gpHash/gpHashLib.c +++ b/src/libCom/gpHash/gpHashLib.c @@ -60,12 +60,13 @@ DEVELOPMENT CENTER AT ARGONNE NATIONAL LABORATORY (708-252-2000). #include #include -#define epicsExportSharedSymbols #include "dbDefs.h" -#include "gpHash.h" #include "ellLib.h" #include "epicsPrint.h" +#define epicsExportSharedSymbols +#include "gpHash.h" + typedef struct gphPvt { int tableSize; int nShift; diff --git a/src/libCom/gpHashLib.c b/src/libCom/gpHashLib.c index 2694ef39d..4b3cbd2b0 100644 --- a/src/libCom/gpHashLib.c +++ b/src/libCom/gpHashLib.c @@ -60,12 +60,13 @@ DEVELOPMENT CENTER AT ARGONNE NATIONAL LABORATORY (708-252-2000). #include #include -#define epicsExportSharedSymbols #include "dbDefs.h" -#include "gpHash.h" #include "ellLib.h" #include "epicsPrint.h" +#define epicsExportSharedSymbols +#include "gpHash.h" + typedef struct gphPvt { int tableSize; int nShift; diff --git a/src/libCom/macCore.c b/src/libCom/macCore.c index e22aec180..95f7a28eb 100644 --- a/src/libCom/macCore.c +++ b/src/libCom/macCore.c @@ -37,9 +37,10 @@ #include #include +#include "dbmf.h" + #define epicsExportSharedSymbols #include "macLib.h" -#include "dbmf.h" /* * Static function prototypes (these static functions provide an low-level @@ -755,6 +756,9 @@ char *Strdup( char *string ) } /* $Log$ + * Revision 1.6 1997/06/05 18:28:48 mrk + * Allow message about referenced but undefined to be suppressed + * * Revision 1.5 1997/05/01 19:57:32 jhill * updated dll keywords * diff --git a/src/libCom/macLib.h b/src/libCom/macLib.h index e1d6878e3..3f66d71b5 100644 --- a/src/libCom/macLib.h +++ b/src/libCom/macLib.h @@ -5,12 +5,23 @@ * William Lupton, W. M. Keck Observatory */ +/* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport +#endif + /* * EPICS include files needed by this file */ #include "ellLib.h" #include "epicsPrint.h" #include "errMdef.h" + +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif #include "shareLib.h" /* @@ -202,6 +213,9 @@ epicsShareAPI macInstallMacros( ); /* $Log$ + * Revision 1.4 1997/06/05 18:28:49 mrk + * Allow message about referenced but undefined to be suppressed + * * Revision 1.3 1997/05/01 19:57:34 jhill * updated dll keywords * diff --git a/src/libCom/macLib/macCore.c b/src/libCom/macLib/macCore.c index e22aec180..95f7a28eb 100644 --- a/src/libCom/macLib/macCore.c +++ b/src/libCom/macLib/macCore.c @@ -37,9 +37,10 @@ #include #include +#include "dbmf.h" + #define epicsExportSharedSymbols #include "macLib.h" -#include "dbmf.h" /* * Static function prototypes (these static functions provide an low-level @@ -755,6 +756,9 @@ char *Strdup( char *string ) } /* $Log$ + * Revision 1.6 1997/06/05 18:28:48 mrk + * Allow message about referenced but undefined to be suppressed + * * Revision 1.5 1997/05/01 19:57:32 jhill * updated dll keywords * diff --git a/src/libCom/macLib/macLib.h b/src/libCom/macLib/macLib.h index e1d6878e3..3f66d71b5 100644 --- a/src/libCom/macLib/macLib.h +++ b/src/libCom/macLib/macLib.h @@ -5,12 +5,23 @@ * William Lupton, W. M. Keck Observatory */ +/* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport +#endif + /* * EPICS include files needed by this file */ #include "ellLib.h" #include "epicsPrint.h" #include "errMdef.h" + +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif #include "shareLib.h" /* @@ -202,6 +213,9 @@ epicsShareAPI macInstallMacros( ); /* $Log$ + * Revision 1.4 1997/06/05 18:28:49 mrk + * Allow message about referenced but undefined to be suppressed + * * Revision 1.3 1997/05/01 19:57:34 jhill * updated dll keywords * diff --git a/src/libCom/postfix.c b/src/libCom/postfix.c index 9eb418d26..ef5ce991f 100644 --- a/src/libCom/postfix.c +++ b/src/libCom/postfix.c @@ -98,8 +98,12 @@ #include #include -#define epicsExportSharedSymbols #include "dbDefs.h" + +#ifdef INCpostfixh +#error postfix.h has been included too soon +#endif +#define epicsExportSharedSymbols #include "postfix.h" diff --git a/src/libCom/postfix.h b/src/libCom/postfix.h index c933d2b34..5f7193933 100644 --- a/src/libCom/postfix.h +++ b/src/libCom/postfix.h @@ -37,6 +37,8 @@ #ifndef INCpostfixh #define INCpostfixh +#include + /* defines for element table */ #define BAD_EXPRESSION 0 #define FETCH_A 1 diff --git a/src/libCom/tsDefs.h b/src/libCom/tsDefs.h index a702f9f04..97d3b9705 100644 --- a/src/libCom/tsDefs.h +++ b/src/libCom/tsDefs.h @@ -56,11 +56,21 @@ extern "C" { #endif -#include "shareLib.h" -#include "epicsTypes.h" + /* Defer declaring export functions until appropriate */ +#ifdef epicsExportSharedSymbols +#undef epicsExportSharedSymbols +#define restoreExport +#endif +#include "epicsTypes.h" #include "errMdef.h" /* get M_ts for this subsystem's `number' */ +#ifdef restoreExport +#define epicsExportSharedSymbols +#undef restoreExport +#endif +#include "shareLib.h" + /*--------------------------------------------------------------------------- - * TS_STAMP @@ -244,20 +254,20 @@ epicsShareFunc long epicsShareAPI tsTimeTextToStamp(); #define TsStatusToText(status) \ (glTsStatText[TsStatusToIndex(status)]) -#ifndef TS_PRIVATE_DATA - epicsShareExtern char *glTsStatText[7]; -#else +epicsShareExtern char *glTsStatText[7]; +#ifdef epicsExportSharedSymbols + /* #error epicsExportSharedSymbols is defined in tsDefs.h */ epicsShareDef char *glTsStatText[] = { - /* S_ts_OK */ "success", - /* S_ts_sysTimeError */ "error getting system time", - /* S_ts_badTextCode */ "invalid TS_TEXT_xxx code", - /* S_ts_inputTextError */ "error in text date or time", - /* S_ts_timeSkippedDST */ "time skipped on switch to DST", - /* S_ts_badRoundInterval */ "rounding interval is invalid", + /* S_ts_OK */ "success", + /* S_ts_sysTimeError */ "error getting system time", + /* S_ts_badTextCode */ "invalid TS_TEXT_xxx code", + /* S_ts_inputTextError */ "error in text date or time", + /* S_ts_timeSkippedDST */ "time skipped on switch to DST", + /* S_ts_badRoundInterval */ "rounding interval is invalid", - /* TS_S_PAST */ "illegal TS status code", + /* TS_S_PAST */ "illegal TS status code", }; -#endif /*TS_PRIVATE_DATA*/ +#endif #ifdef __cplusplus } diff --git a/src/libCom/tsSubr.c b/src/libCom/tsSubr.c index 1bd8db7d6..56def0522 100644 --- a/src/libCom/tsSubr.c +++ b/src/libCom/tsSubr.c @@ -119,10 +119,6 @@ #include #include -#define TS_PRIVATE_DATA -#include "tsDefs.h" -#undef TS_PRIVATE_DATA - #if defined(vxWorks) # include # include "drvTS.h" @@ -138,9 +134,14 @@ # include #endif -#define epicsExportSharedSymbols #include "epicsAssert.h" #include "envDefs.h" + +#define epicsExportSharedSymbols +/* The instance of glTsStatText[] will be defined */ +#include "tsDefs.h" + + /*/subhead configuration------------------------------------------------------ * C O N F I G U R A T I O N D E F I N I T I O N S