diff --git a/harbour/ChangeLog b/harbour/ChangeLog index aed853d6ae..ba2faa5ef5 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,33 @@ +Tue May 11 18:53:43 1999 Gonzalo A. Diethelm + + * Makefile: + Added obj to the list of directories. + + * source/Makefile: + Added rdd to the list of directories. + + * source/rtl/Makefile: + Added gtapi.c to the list of C sources. + + * source/rtl/gtapi.c: + Got rid of two warnings with gcc. + + * source/rtl/environ.c: + Made sure it compiles with gcc. + There was a missing #endif. + + * source/tools/stringp.prg: + * tests/working/debugtst.prg: + Replaced Debug() with HBDebug(), otherwise the generated C source + collides with the macro DEBUG. + + * source/vm/hvm.c: + Corrected a comment. + + * source/rdd/Makefile: + * obj/Makefile: + Added these two Makefiles. + 19990511-19:20 Eddie Runia * source/rtl/classes.c (Default) parameter self added to INLINE methods diff --git a/harbour/Makefile b/harbour/Makefile index 3d9ff2350f..3d2d97d6c4 100644 --- a/harbour/Makefile +++ b/harbour/Makefile @@ -6,6 +6,7 @@ ROOT = ./ DIRS=\ source \ + obj \ tests \ include $(ROOT)config/dir.cf diff --git a/harbour/obj/Makefile b/harbour/obj/Makefile new file mode 100644 index 0000000000..900a02c8ec --- /dev/null +++ b/harbour/obj/Makefile @@ -0,0 +1,7 @@ +# +# $Id$ +# + +ROOT = ../ + +include $(TOP)$(ROOT)config/dir.cf diff --git a/harbour/source/Makefile b/harbour/source/Makefile index 39e953527d..a9ce5861f9 100644 --- a/harbour/source/Makefile +++ b/harbour/source/Makefile @@ -8,6 +8,7 @@ DIRS=\ compiler \ rtl \ vm \ + rdd \ tools \ include $(ROOT)config/dir.cf diff --git a/harbour/source/rdd/Makefile b/harbour/source/rdd/Makefile new file mode 100644 index 0000000000..1573c81978 --- /dev/null +++ b/harbour/source/rdd/Makefile @@ -0,0 +1,7 @@ +# +# $Id$ +# + +ROOT = ../../ + +include $(TOP)$(ROOT)config/dir.cf diff --git a/harbour/source/rtl/Makefile b/harbour/source/rtl/Makefile index 83d0f3dab6..3ae8aa730f 100644 --- a/harbour/source/rtl/Makefile +++ b/harbour/source/rtl/Makefile @@ -14,6 +14,7 @@ C_SOURCES=\ errorapi.c \ extend.c \ files.c \ + gtapi.c \ itemapi.c \ math.c \ set.c \ diff --git a/harbour/source/rtl/environ.c b/harbour/source/rtl/environ.c index de1be37316..c1bf64e5c4 100644 --- a/harbour/source/rtl/environ.c +++ b/harbour/source/rtl/environ.c @@ -6,6 +6,12 @@ HARBOUR OS() { +#ifdef __GNUC__ + + _retc("UNKNOWN"); + +#else + /* TODO: add MSVC support but MSVC cannot detect any OS except Windows! */ #if defined(__TURBOC__) || defined(__BORLANDC__) @@ -57,6 +63,8 @@ HARBOUR OS() _retc("OS/2"); } +#endif /* WATCOMC */ + /* TODO: get Windows version (major, minor) */ /* detect Windows */ regs.w.ax = 0x160A; @@ -90,6 +98,8 @@ HARBOUR OS() /* TODO: detect other OSes */ /* TODO: detect MS-DOS version */ _retc("MS-DOS"); + +#endif /* __GNUC__ */ } HARBOUR VERSION() diff --git a/harbour/source/rtl/gtapi.c b/harbour/source/rtl/gtapi.c index f4fcbf08a6..648471cc53 100644 --- a/harbour/source/rtl/gtapi.c +++ b/harbour/source/rtl/gtapi.c @@ -37,6 +37,8 @@ int _gtMaxCol( void ) gettextinfo( &ti ); return ti.screenwidth; + #else + return 0; #endif } @@ -47,6 +49,8 @@ int _gtMaxRow( void ) gettextinfo( &ti ); return ti.screenheight; + #else + return 0; #endif } diff --git a/harbour/source/tools/stringp.prg b/harbour/source/tools/stringp.prg index c954c2360c..107273a299 100644 --- a/harbour/source/tools/stringp.prg +++ b/harbour/source/tools/stringp.prg @@ -106,12 +106,12 @@ function ToChar( xTxt, cSeparator, lDebug ) return cOut // -// Debug ( ) +// HBDebug ( ) // // Non-volatile debugging function showing contents of xItem and returing // passed argument. // -function Debug( xItem ) +function HBDebug( xItem ) QOut( ToChar( xItem, ", ", .T. ) ) diff --git a/harbour/source/vm/hvm.c b/harbour/source/vm/hvm.c index 6fc674d316..1cb07fbc16 100644 --- a/harbour/source/vm/hvm.c +++ b/harbour/source/vm/hvm.c @@ -107,7 +107,7 @@ void StackPop( void ); /* pops an item from the stack */ void StackFree( void ); /* releases all memory used by the stack */ void StackPush( void ); /* pushes an item on to the stack */ void StackInit( void ); /* initializes the stack */ -void StackShow( void ); /* show the types of the items on the stack for HBDEBUGging purposes */ +void StackShow( void ); /* show the types of the items on the stack for debugging purposes */ PCODEBLOCK CodeblockNew( BYTE *, WORD, PSYMBOL, int, WORD ); void CodeblockDelete( PCODEBLOCK ); diff --git a/harbour/tests/working/debugtst.prg b/harbour/tests/working/debugtst.prg index 738ba8eb1d..fd520535aa 100644 --- a/harbour/tests/working/debugtst.prg +++ b/harbour/tests/working/debugtst.prg @@ -18,7 +18,7 @@ function Main() QOut( "-OBJECT additions-" ) QOut( "What is in oForm ? " ) - Debug( oForm:Transfer() ) + HBDebug( oForm:Transfer() ) QOut( "Does transfer exists ? ", IsMessage( oForm, "Transfer" ) ) QOut( "Is transfer DATA ? ", IsData ( oForm, "Transfer" ) ) @@ -32,23 +32,23 @@ function Main() QOut( "Set nLeft to 50 and nRight to 100" ) oForm:Transfer( {"nLeft", 50}, {"nRight", 100} ) - Debug( oForm:Transfer() ) + HBDebug( oForm:Transfer() ) Pause() QOut( "-DEBUG Functions-") QOut( "-Statics-" ) - Debug( __aStatic() ) + HBDebug( __aStatic() ) QOut( "-Global Stack-" ) - Debug ( __aGlobalStack() ) + HBDebug ( __aGlobalStack() ) QOut( "-Local Stack-" ) - Debug ( __aStack() ) + HBDebug ( __aStack() ) QOut( "-Parameters-" ) - Debug ( __aParam() ) + HBDebug ( __aParam() ) Pause() @@ -73,19 +73,19 @@ function FuncSecond( nParam, cParam, uParam ) QOut() QOut( "-Statics-" ) - Debug ( __aStatic() ) + HBDebug ( __aStatic() ) QOut() QOut( "-Global Stack- Len=", __GlobalStackLen() ) - Debug ( __aGlobalStack() ) + HBDebug ( __aGlobalStack() ) QOut() QOut( "-Local Stack- Len=", __StackLen() ) - xStack := Debug ( __aStack() ) + xStack := HBDebug ( __aStack() ) QOut() QOut( "-Parameters-" ) - xParam := Debug( __aParam() ) + xParam := HBDebug( __aParam() ) if xParam[ xStack[ 7 ] ] == "Hello" QOut( ":-)" ) endif