On Wed, 16 Dec 2009, Pritpal Bedi wrote:

Hi,

> Now I can trace PRG level calls in HBIDE with -D__HB_DEBUG__ define
> which in turn invokes hb_TraceString( [x,,,,] ) which in turn executes
> hb_tr_trace( HB_TR_ALWAYS,.. ).
> But still I cannot capture HBQT HB_TRACE( HB_TR_DEBUG, ... ) calls.
> HBQT compiles and shows up this in log:
> gcc   -I. -I../../../../../include -Wall -W -O3 -fomit-frame-pointer
> -march=i586 -mtune=pentiumpro  -Ic:\Qt\2009.03\qt\include
> -Ic:\Qt\2009.03\qt\include/QtCore -Ic:\Qt\2009.03\qt\include/QtGui
> -Ic:\Qt\2009.03\qt\include/QtNetwork -D__HB_WINDEBUG__ -D__HB_DEBUG__
> -DHB_FM_STATISTICS -DHB_TR_LEVEL_DEBUG -ohbqt_destruct.o -c
> ../../../hbqt_destruct.cpp

I have no idea what __HB_WINDEBUG__ does. As I can see it's not used at all.
__HB_DEBUG__ is you own macro used in hbqt.ch to disable HBQT_DEBUG() debug
messages  in .prg code so it does not have to be passed to compile C code.
Remove both from your HB_USER_CFLAG settings.

> which amply shows that HB_TR_LEVEL_DEBUG is passed to the compiler.

And this is correct so all HB_TR_DEBUG level HB_TRACE() messages are
not stripped at compile time by C preprocessor and later can be enabled
at runtime.

> Other envar set are : HB_TR_WINOUT=1
> What I am missing ?
> Note that I am looking at output rendered by OutputDebugString() call in
> hbtrace.c.
> Moreover, in PRG level trace shows up info as:
> trace.c:96: HB_TR_ALWAYS          0 Destroy: XBPTOOLBAR      1375326     
> 20376
> and there trace.c:96 is the wrong info.

You forgot to switch the runtime HB_TRACE message filter level so it's
still set to HB_TR_WARNING and ignores all massages having HB_TR_INFO or
HB_TR_DEBUG level.
   set HB_TR_LEVEL=DEBUG
change this filter from WARNING to DEBUG level.
Just make few tests with code example I sent using different compiletime
and runtime filters.

best regards,
Przemek
_______________________________________________
Harbour mailing list (attachment size limit: 40KB)
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to