# ***************************************************************************
# *
# *  Oxford Semiconductor Proprietary and Confidential Information
# *
# *  Copyright:      Oxford Semiconductor Ltd, 2006
# *
# *  Description:    Event tracing part of the sources file.
# *
# ***************************************************************************

# Comment the below line to disable tracing. All the debug traces
# will be sent to the kernel-debugger (for debug builds).
#ENABLE_EVENT_TRACING=1


!IFDEF ENABLE_EVENT_TRACING

C_DEFINES = $(C_DEFINES) -DEVENT_TRACING

# Generate WPP tracing code
# $(SOURCES)   -- run software preprocessor on files listed in SOURCES
# -km          -- use kernel mode
# -dll         -- needed for .CPP
# -func        -- define function we'll use for tracing
#                 This would map all OsTrace calls to DoTraceMessage.
RUN_WPP= $(SOURCES)                                                  \
         -km                                                         \
         -dll                                                        \
         -func:OsTrace(LEVEL,FLAGS,MSG,...)                          \
         -func:OsTraceCond(LEVEL,FLAGS,COND,MSG,...)                 \
         -func:Hexdump((LEVEL,FLAGS,MSG,...))                        \
         -func:PRECONDITION{ASSERTFLAG=TRACE_FLAG_ASSERT}(COND)      \
         -func:POSTCONDITION{ASSERTFLAG=TRACE_FLAG_ASSERT}(COND)     \
         -func:EXPECT{ASSERTFLAG=TRACE_FLAG_ASSERT}(COND)            \
         -func:PATH_NOT_YET_TESTED{LEVEL=TRACE_LEVEL_WARNING,FLAGS=TRACE_FLAG_PATH_TRACE}(...)

!ENDIF
