From 52034a508b378d91b0b50d7a36d36f00d6aa06e1 Mon Sep 17 00:00:00 2001 From: Ron Sluiter Date: Tue, 21 Dec 2004 18:53:22 +0000 Subject: [PATCH] Debug messages conditioned on DEBUG macro. --- motorApp/MotorSrc/motordrvCom.cc | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/motorApp/MotorSrc/motordrvCom.cc b/motorApp/MotorSrc/motordrvCom.cc index b028920a..a883f3f2 100644 --- a/motorApp/MotorSrc/motordrvCom.cc +++ b/motorApp/MotorSrc/motordrvCom.cc @@ -3,9 +3,9 @@ FILENAME... motordrvCom.cc USAGE... This file contains driver functions that are common to all motor record driver modules. -Version: $Revision: 1.11 $ +Version: $Revision: 1.12 $ Modified By: $Author: sluiter $ -Last Modified: $Date: 2004-09-20 20:39:55 $ +Last Modified: $Date: 2004-12-21 18:53:22 $ */ /* @@ -57,13 +57,17 @@ Last Modified: $Date: 2004-09-20 20:39:55 $ /*----------------debugging-----------------*/ -volatile int motordrvComdebug = 0; -epicsExportAddress(int, motordrvComdebug); #ifdef __GNUG__ - #define Debug(l, f, args...) {if (l <= motordrvComdebug) printf(f, ## args);} + #ifdef DEBUG + #define Debug(l, f, args...) {if (l <= motordrvComdebug) printf(f, ## args);} + #else + #define Debug(l, f, args...) + #endif #else #define Debug() #endif +volatile int motordrvComdebug = 0; +extern "C" {epicsExportAddress(int, motordrvComdebug);} /* Function declarations. */