Ignore:
Timestamp:
Nov 25, 2011, 10:19:52 PM (14 years ago)
Author:
dmik
Message:

Make the debug version of ported DLLs build.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/gcc-kmk/include/dbglog.h

    r21717 r21824  
    9999
    100100/* enable support for the _interrupt() statement */
    101 #if (defined(__IBMCPP__) || defined(__IBMC__))
     101#if defined(__IBMCPP__) || defined(__IBMC__) || defined(__GNUC__)
     102
     103#ifndef __GNUC__
    102104#  include <builtin.h>
     105#endif
     106
    103107#ifdef DEBUG
     108
    104109#ifdef __cplusplus
    105110
    106 #define DebugInt3() BreakPoint(__FILE__, __FUNCTION__, __LINE__)
     111#ifdef PRIVATE_LOGGING
     112#define DebugInt3() do { \
     113    dprintf((LOG, "BREAKPOINT %s %s %d", __FILE__, __FUNCTION__, __LINE__)); \
     114    _interrupt(3); \
     115} while (0)
     116#else
     117#define DebugInt3() do { \
     118    dprintf(("BREAKPOINT %s %s %d", __FILE__, __FUNCTION__, __LINE__)); \
     119    _interrupt(3); \
     120} while (0)
     121#endif
    107122
    108 void inline BreakPoint(const char *szFile, const char *szFunction, int iLine)
    109 {
    110     dprintf(("BREAKPOINT %s %s %d", szFile, szFunction, iLine));
    111     _interrupt(3);
    112 }
    113 
    114 #else
     123#else /* __cplusplus */
    115124  #define DebugInt3()   _interrupt(3)
    116125#endif
    117 #else
     126
     127#else /* DEBUG */
    118128  #define DebugInt3()
    119129#endif
    120130
    121 #else
     131#else /* defined(__IBMCPP__) || defined(__IBMC__) || defined(__GNUC__) */
     132
    122133#ifdef DEBUG
    123134  #define DebugInt3()   _asm int 3;
     
    126137#endif
    127138
    128 #endif
     139#endif /* defined(__IBMCPP__) || defined(__IBMC__) || defined(__GNUC__) */
    129140
    130141#ifdef __cplusplus
Note: See TracChangeset for help on using the changeset viewer.