Commit Graph

336 Commits

Author SHA1 Message Date
Viktor Szakats
ca828aaca4 2008-11-07 17:48 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* bin/hbmk.bat
    + Added support for 'owatcom' as HB_COMPILER.
    ; NOTE: If there are no objections I'll remove Harbour 
            support for 'watcom' HB_COMPILER, which was 
            used for old non-opensource version of this 
            compiler, but I guess it doesn't make too much 
            sense having them anymore.

  * source/common/hbverdsp.c
    * Minor change in /build output.

  * include/hbver.ch
  * source/rtl/version.c
    * Changed ordering of parameter constants to make more sense.

  * bin/hbmk.bat
  * config/w32/owatcom.cf
    * Removed 'debug all' linker option to make executable sizes 
      significantly smaller by default. If you need debug info, 
      use 'L_USR=debug all'.
    ; NOTE: I'd suggest doing the same for other platform supported 
            by owatcom. If there are no objections I can do this.

  * source/rtl/gtwvt/gtwvt.c
    * Typo, minor formatting.
2008-11-07 16:54:27 +00:00
Viktor Szakats
1207ad9dbb 2008-11-06 09:07 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* common.mak
  * source/vm/Makefile
  * source/vm/vmmt/Makefile
  * source/common/Makefile
  * source/rtl/Makefile
  - source/vm/fmhb.c
  + source/rtl/fmhb.c
  - source/vm/hbmem.c
  + source/common/hbmem.c
    * Moved hbfm (MEMORY() .prg function) from VM to RTL.
    * Moved hbmem (hb_xmem*() C functions) from VM to COMMON.

  - contrib/hbziparc/hbzipcpp.old
    - Removed.
2008-11-06 08:09:13 +00:00
Viktor Szakats
ccd1a88f7b 2008-11-05 19:16 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* bin/hb-func.sh
  * include/hbstdgen.ch
  * include/hbver.h
  * contrib/examples/pp/pp.c
  * source/pp/ppcore.c
  * source/pp/hbpp.c
  * source/common/hbver.c
    * HB_VER_REVISION -> HB_VER_RELEASE.
      INCOMPATIBLE.
2008-11-05 18:19:06 +00:00
Viktor Szakats
294d83814d 2008-11-02 14:28 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* include/hbextern.ch
    ! Added all missing LANG and CODEPAGE modules.
      [TOMERGE 1.0]

  * ChangeLog
    - Removed duplicate entry of mine.

  * source/common/hbstr.c
  * source/rtl/version.c
  * source/rtl/filesys.c
    * Minor formatting.

  * source/codepage/cpcs852.c
  * source/codepage/cpsk852.c
  * source/codepage/cpcsiso.c
  * source/codepage/cpcswin.c
  * source/codepage/cpskiso.c
  * source/codepage/cpskwin.c
  * source/codepage/cpcskam.c
  * source/codepage/cpskkam.c
    * Removed unnecessary ending ';'
2008-11-02 13:29:00 +00:00
Viktor Szakats
dddbc1c824 2008-11-02 07:33 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* include/hbstdgen.ch
    - Removed HB_VERSION mistakenly left there.

  * include/hbextern.ch
  * source/rtl/version.c
    + Added HB_OSISWINNT()
    + Added HB_OSISWINCE()
      [TOMERGE 1.0]

  * include/hbver.ch
  * source/rtl/version.c
    + Added:
      hb_version( HB_VERSION_MT )          -> <logical>
      hb_version( HB_VERSION_UNIX_COMPAT ) -> <logical>
      hb_version( HB_VERSION_PLATFORM )    -> <string> (same as ending of __PLATFORM__* macros)
      This makes these functions/macros deprecated:
      - HB_MTVM()
      - __PLATFORM__* (not for all possible situations)
    ; TOFIX: Cleanup REVISION/SVN term usage in source.
    ; TOFIX: Remove HB_VER_* predefined macro usage on .prg level.
    ; TODO: Removed some deprecated by hb_version() functions/macros.

  * include/hbapi.h
  * source/vm/itemapi.c
  * source/common/hbstr.c
  * source/common/expropt2.c
  * source/rtl/chrasc.c
  * source/rtl/hbi18n.c
    * Minor formatting.
2008-11-02 06:34:42 +00:00
Przemyslaw Czerpak
989f28dd47 2008-11-01 13:41 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/common/hbgete.c
    ! fixed OS2 casting for non GCC compilers
2008-11-01 12:41:08 +00:00
Przemyslaw Czerpak
ecc87c1bf3 2008-10-31 13:54 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/vm/dynlibhb.c
  * harbour/source/common/hbgete.c
  * harbour/source/common/hbfsapi.c
  * harbour/source/rtl/hbinet.c
  * harbour/source/rtl/hbffind.c
  * harbour/source/rtl/filesys.c
  * harbour/contrib/hbct/files.c
  * harbour/contrib/hbmzip/hbmzip.c
  * harbour/contrib/hbgf/hbgfos2/os2pm.c
    * cleanup casting in OS2 builds (use PCSZ/PSZ)
2008-10-31 12:53:52 +00:00
Viktor Szakats
011f9978ad 2008-10-30 00:10 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* ChangeLog
    + Clarification to previous entry.

  * source/common/hbgete.c
  * source/common/hbfsapi.c
    ! Blind fix for OS/2 compiler warnings. David, please test.

  * source/rtl/philes.c
    * Minor (0 -> '\0').

  * source/compiler/hbusage.c
    ! Fixed old typo in help text.
    ; BTW: What is missing for gettext support?
2008-10-29 23:11:35 +00:00
Przemyslaw Czerpak
a398da282e 2008-10-29 17:06 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbcompdf.h
  * harbour/include/hbexprb.c
  * harbour/source/common/expropt1.c
  * harbour/source/common/expropt2.c
    ! change the expressions precedence - references to variables were
      wrongly marked as simple expressions

  * harbour/include/hbexpra.c
    ! fixed protection against wrong static initializers. Now code like:
         static s_var := { { func(), M->var } }
      or:
         static s_var := { "A" => { func() => M->var } }
      or:
         static s_var := { @M->var }
      or:
         static s_var := QSelf()
      is not accepted by compiler and error is generated at compile
      time instead of crashing at HVM startup when static variables
      are initialized
2008-10-29 16:06:31 +00:00
Viktor Szakats
c4636942ec 2008-10-27 21:43 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* contrib/Makefile
  * contrib/make_vc_all.bat
  * contrib/make_b32_all.bat
  * contrib/make_gcc_all.sh
    + Added rddsql to default builds.
      Please test.

  * contrib/hbdbgfx/dbgfxc.c
    * Added TODO. (multiplatform support in one the functions)

  * include/hbsetup.h
  * include/hbexprb.c
  * contrib/hbct/ctnet.c
  * contrib/hbct/color.c
  * contrib/hbct/dattime2.c
  * contrib/xhb/hboutdbg.c
  * contrib/hbtpathy/tpwin32.c
  * contrib/hbmzip/hbmzip.c
  * contrib/hbsqlit3/hbsqlit3.c
  * contrib/hbfbird/firebird.c
  * contrib/hbziparc/hbzipcpp.old
  * contrib/hbnf/getver.c
  * contrib/hbpgsql/postgres.c
  * contrib/hbclipsm/gauge.c
  * contrib/rddads/adsfunc.c
  * contrib/rddads/ads1.c
  * contrib/hbgd/gdwrp.c
  * contrib/hbmisc/spd.c
  * contrib/hbtip/utils.c
  * contrib/hbwin/win_prt.c
  * contrib/examples/pp/hbppcore.c
  * contrib/examples/pp/hbppcomp.c
  * source/pp/pplib.c
  * source/pp/ppcore.c
  * source/pp/hbpp.c
  * source/vm/estack.c
  * source/vm/debug.c
  * source/vm/itemapi.c
  * source/vm/hvm.c
  * source/vm/cmdarg.c
  * source/vm/fm.c
  * source/vm/extrap.c
  * source/vm/classes.c
  * source/main/harbour.c
  * source/common/hbver.c
  * source/common/hbverdsp.c
  * source/common/hbstr.c
  * source/common/hbdate.c
  * source/rtl/gtxwc/gtxwc.c
  * source/rtl/hbgtcore.c
  * source/rtl/gtcrs/gtcrs.c
  * source/rtl/errorint.c
  * source/rtl/gtsln/gtsln.c
  * source/rtl/gttrm/gttrm.c
  * source/rtl/gtpca/gtpca.c
  * source/rtl/fkmax.c
  * source/rtl/langapi.c
  * source/rtl/hbffind.c
  * source/rdd/workarea.c
  * source/rdd/sdf1.c
  * source/rdd/delim1.c
  * source/rdd/dbf1.c
  * source/rdd/wafunc.c
  * source/compiler/hbmain.c
  * source/compiler/cmdcheck.c
  * source/compiler/hbpcode.c
  * source/compiler/genhrb.c
  * source/compiler/gencobj.c
  * source/compiler/genobj32.c
  * source/compiler/genc.c
  * source/compiler/hbusage.c
  * source/compiler/hbfunchk.c
  * source/compiler/hbgenerr.c
  * utils/hbmake/hbmgauge.c
    * Changed snprintf() calls to hb_snprintf().
    ; TODO: Finish the mappings in headers.

  * tests/wvtext.prg
  * include/inkey.ch
  * source/rtl/gtwvt/gtwvt.c
    * Changed K_HB_RESIZE to HB_K_RESIZE. The reason is 
      that we already got a HB_K_MULTICODE code (few lines 
      below, I didn't know about it before), and it's better 
      to keep consistency with that.
2008-10-27 20:55:24 +00:00
Viktor Szakats
d1dc70f971 2008-10-27 12:03 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* make_vc.mak
  * contrib/mtpl_vc.mak
    - Removed no longer necessary '-D_CRT_SECURE_NO_DEPRECATE' 
      for MSVS 2005 and upper.

  * include/hbsetup.h
    * Mapping snprintf() calls to hb_snprintf().
    ; TODO: Replace the calls in source code.

  * source/common/hbstr.c
    ! Fixed hb_snprintf(). Please verify on your platforms.
    ; TODO: It may need further tweaking to smooth out the 
            platform implementation differences.
2008-10-27 11:11:02 +00:00
Viktor Szakats
b5e9969713 2008-10-27 11:29 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* include/hbapi.h
  * source/common/hbstr.c
    + Added return value to hb_snprintf().
2008-10-27 10:30:03 +00:00
Viktor Szakats
bfd31350c2 2008-10-27 11:26 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbstr.c
    * Some tweaks to hb_snprintf(). It still doesn't work 
      for some reason.

  * include/hbapi.h
    + Added hb_snprintf() to header.

  * source/debug/dbgentry.c
    * Changed strcpy() to hb_strncpy(). Chances are high 
      this is wrong. Please review and test.
2008-10-27 10:26:54 +00:00
Viktor Szakats
32909568c0 2008-10-27 00:01 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbver.c
    * Changed to include bitness even for DJGPP.
    * Changed "(* bit)" to "(*-bit)"
    ; NOTE: We have __ARCH*BIT__ but this macro is misleading 
            and cannot be used properly on platforms where the 
            compiler is able to generate multiple targets in 
            one build pass. Such system is Darwin/OSX.
            I'd suggest to consider removing this macro, and 
            rather adding a function to return bitness.
            Any opininons?
2008-10-26 23:04:57 +00:00
Viktor Szakats
79708d30b0 2008-10-26 22:25 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbfopen.c
    * Changed hb_fopen() to use fopen_s(), secure version of 
      fopen() for MSVS 2005 and upper.

  * source/common/hbstr.c
    + Added hb_snprintf() Harbour wrapper for snprintf() which 
      terminates the buffer with a '\0' char for CRTLs that 
      need this (like MSVC).
      MSVC _snprintf() doesn't do so.
    * hb_snprintf() used _snprintf_s(), secure version of 
      _snprintf() for MSVS 2005 and upper.
    ; TOFIX: There is still one strcpy() marked as non-secure 
             in debug lib. Could someone please take a look 
             at it and replace it with hb_strncpy() or something 
             else secure? The code is cryptic and as someone 
             not using the debugger, I didn't dare to touch it, 
             and this is the only one such call left.
    ; TODO: Change all snprintf() calls to hb_snprintf().
            When that happens, Harbour will no more use anything 
            depicted as "non-secure" by MSVS 2005/2008.
    ; NOTE: This function may need tweaking, pls review and 
            fix if/where needed.

  * source/vm/dlmalloc.c
    ! Fixed MSVC C++ mode compile error. This fix also exists 
      as part of the next dlmalloc version (2.8.4b).

2008-10-26 07:27 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
  * contrib/hbdbgfx/dbgfx.prg
    * Minor cleanup.
 
  * contrib/hbdbgfx/dbgfxc.c
    ! Fixed GPF when non-string parameter passed to 
      hb_outdebug().
2008-10-26 21:43:34 +00:00
Przemyslaw Czerpak
47ed35ee5c 2008-10-22 17:45 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/bin/hbmk.bat
    * simple modification to make beginning hbmk parameters (-mt and -gui)
      position independent though they still have to be used before Harbour/
      C compiler switches and filenames

  * harbour/source/common/hbdate.c
  * harbour/source/compiler/cmdcheck.c
  * harbour/source/rtl/filesys.c
  * harbour/source/rtl/hbffind.c
    ! use MT safe localtime_r() function if it's available instead of
      localtime()
      TODO: clean the usage of this function and gmttime[_r]() probably
      by adding our own wrappers.

  * harbour/source/rtl/hbffind.c
    ! disabled calls to tzset() - this function should be executed
      automatically by CRTL only if it's necessary. It's also not MT
      safe and can cause MT applications crash.
2008-10-22 15:45:36 +00:00
Viktor Szakats
c3f2ef56f9 2008-10-18 21:16 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbgete.c
    ! Fixed recent warning on Win32 platforms.

  * contrib/xhb/hbcrypt.c
    * Changed to just work instead of RTE-in if any 
      of the params are empty on non-strings. If 
      non-string is passed, it's considered as 
      empty string.
2008-10-18 19:18:17 +00:00
Viktor Szakats
a0bf4555ef 2008-10-18 16:15 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
- bin/bld.bat
  + bin/hbmk.bat
  - bin/bld_os2.cmd
  + bin/hbmk_os2.cmd
  - bin/bld_b32.bat
  + bin/hbmk_b32.bat
  - bin/bld_vc.bat
  + bin/hbmk_vc.bat
  * tests/bld_b32.bat
  * tests/bld_vc.bat
  * contrib/hbmysql/tests/bld_b32.bat
  * contrib/hbmysql/tests/bld_vc.bat
  * contrib/hbct/tests/bld_b32.bat
  * contrib/hbct/tests/bld_vc.bat
  * contrib/xhb/tests/bld_b32.bat
  * contrib/xhb/tests/bld_vc.bat
  * contrib/hbodbc/tests/bld_b32.bat
  * contrib/hbodbc/tests/bld_vc.bat
  * contrib/hbtpathy/tests/bld_b32.bat
  * contrib/hbtpathy/tests/bld_vc.bat
  * contrib/hbmzip/tests/bld_b32.bat
  * contrib/hbmzip/tests/bld_vc.bat
  * contrib/hbole/tests/bld_b32.bat
  * contrib/hbole/tests/bld_vc.bat
  * contrib/hbsqlit3/tests/bld_b32.bat
  * contrib/hbsqlit3/tests/bld_vc.bat
  * contrib/hbapollo/tests/bld_b32.bat
  * contrib/hbapollo/tests/bld_vc.bat
  * contrib/hbfbird/tests/bld_b32.bat
  * contrib/hbfbird/tests/bld_vc.bat
  * contrib/hbziparc/tests/bld_b32.bat
  * contrib/hbziparc/tests/bld_vc.bat
  * contrib/hbnf/tests/bld_b32.bat
  * contrib/hbnf/tests/bld_vc.bat
  * contrib/hbcurl/tests/bld_b32.bat
  * contrib/hbcurl/tests/bld_vc.bat
  * contrib/hbhpdf/tests/bld_b32.bat
  * contrib/hbhpdf/tests/bld_vc.bat
  * contrib/rddado/tests/bld_b32.bat
  * contrib/rddado/tests/bld_vc.bat
  * contrib/gtwvg/tests/bld_vc.bat
  * contrib/gtwvg/tests/bld_b32.bat
  * contrib/hbpgsql/tests/bld_b32.bat
  * contrib/hbpgsql/tests/bld_vc.bat
  * contrib/hbclipsm/tests/bld_b32.bat
  * contrib/hbclipsm/tests/bld_vc.bat
  * contrib/rddads/tests/bld_b32.bat
  * contrib/rddads/tests/bld_vc.bat
  * contrib/hbfimage/tests/bld_b32.bat
  * contrib/hbfimage/tests/bld_vc.bat
  * contrib/hbgd/tests/bld_vc.bat
  * contrib/hbgd/tests/bld_b32.bat
  * contrib/hbmisc/tests/bld_b32.bat
  * contrib/hbmisc/tests/bld_vc.bat
  * contrib/hbgf/tests/bld_b32.bat
  * contrib/hbgf/tests/bld_vc.bat
  * contrib/hbtip/tests/bld_vc.bat
  * contrib/hbtip/tests/bld_b32.bat
  * contrib/hbwin/tests/bld_b32.bat
  * contrib/hbwin/tests/bld_vc.bat
  * contrib/hbvpdf/tests/bld_b32.bat
  * contrib/hbvpdf/tests/bld_vc.bat
  * contrib/hbwhat/tests/bld_b32.bat
  * contrib/hbwhat/tests/bld_vc.bat
  * contrib/examples/hbsqlit2/tests/bld_b32.bat
  * contrib/examples/hbsqlit2/tests/bld_vc.bat
    * Renamed bin\bld*.* files to bin\hbmk*.*. This 
      dir may be put in the path in user environments, 
      so it's necessary to put the name into the Harbour 
      namespace. The new name is also the one supported 
      on *nix/bash platforms, albeit with slightly 
      different usage.
      INCOMPATIBLE. Please update your environment.
      To achieve compatbility with older Harbour versions 
      and xhb, you can locally add a bld.bat file with 
      the content: '@call hbmk.bat %1 %2 %3 %4 %5 %6 %7 %8 %9'

  * source/common/hbgete.c
    * Minor.
2008-10-18 14:23:58 +00:00
Przemyslaw Czerpak
25fe51e9e5 2008-10-18 11:39 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/common/hbgete.c
    * modified hb_getenv_buffer() to return logical value indicating
      that environment variable exists even if no buffer is passed
2008-10-18 09:39:42 +00:00
Viktor Szakats
ee26c1b8d6 2008-10-18 10:27 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* include/hbapi.h
  * source/common/hbgete.c
    + Added hb_getenv_buffer(). Similar to hb_getenv() but 
      this one needs a buffer+size to be passed, so no memory 
      allocation is done by the function. It also return 
      a BOOL to signal success. It doesn't signal if passed 
      buffer was too small to store the value.
2008-10-18 08:28:50 +00:00
Przemyslaw Czerpak
f97d4e1cda 2008-10-13 21:30 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbwince.h
  * harbour/source/common/hbwince.c
    ! fixed LastError overwriting inside WinCE wrapper functions
2008-10-13 19:30:38 +00:00
Przemyslaw Czerpak
4176d85bb7 2008-10-11 11:21 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/common/expropt2.c
    * formatting and minor cleanup

  * harbour/source/rtl/gtapi.c
    % do not set and restore default color set in hb_gtPutText() and
      hb_gtDrawBox() but decode colors from passed string
2008-10-11 09:21:52 +00:00
Viktor Szakats
9e70689436 2008-10-06 21:27 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* include/hbapifs.h
   * include/hbextern.ch
   * source/common/hbfsapi.c
   * source/rtl/hbfile.c
     + Added hb_fsNameExists() C level function.
     + Added hb_FNameExists() Harbour level function.
     ; Both will return true if any kind of directory entry 
       exists with the given name (IOW it doesn't matter 
       if it's a file or directory, or else).
2008-10-06 19:30:27 +00:00
Przemyslaw Czerpak
67cc2f7ebe 2008-10-06 15:30 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbthread.h
  * harbour/source/vm/thread.c
  * harbour/source/vm/hvm.c
    + add numeric HVM thread identifiers to thread structure. Now
      HB_THREADID() returns numbers in all OSes

  * harbour/include/hbexprop.h
  * harbour/include/hbexprb.c
  * harbour/source/common/expropt2.c
    + added compile time optimization for MIN() and MAX() functions

  * harbour/source/rtl/minmax.c
    * removed trailing spaces from source code
2008-10-06 13:30:47 +00:00
Przemyslaw Czerpak
9440cf8e4c 2008-09-23 21:42 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/bin/hb-func.sh
    * use HB_IMPORT instead of hardcoded attributes in hb* scripts

  * harbour/source/common/hbver.c
    * generate different info for POCC and XCC compilers

  * harbour/source/rdd/dbfcdx/dbfcdx1.c
    * reduce header validation to not report clipper indexes as corrupted
2008-09-23 19:43:34 +00:00
Przemyslaw Czerpak
c8d341cefb 2008-09-23 15:38 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/vm/codebloc.c
    * updated old and not longer valid comment

  * harbour/source/vm/memvars.c
    * minor code formatting

  * harbour/source/common/expropt2.c
    ! fixed bug in power math expression optimization caused
      by two lines left in the code by mistake. Many thanks to
      Maurilio for locating the problem.

  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
  * harbour/source/vm/hvm.c
    % added support for buffering hb_stack TLS access be preloading
      the stack pointer into C stack function local variables.
      Please make speed tests for MT mode with different C compilers
      and different platforms.
2008-09-23 13:39:35 +00:00
Przemyslaw Czerpak
a8aac5cae5 2008-09-22 02:34 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbvm.h
  * harbour/source/vm/hvm.c
  * harbour/source/vm/thread.c
    + added .prg function hb_threadSelf() -> <pThID> | NIL
      It returns thread ID pointer variable or NIL when thread was
      registered without it (main thread and some 3-rd party threads
      created by C API)

  * harbour/source/vm/hvm.c
    * protect s_InitFunctions and s_ExitFunctions by mutex

  * harbour/source/common/hbverdsp.c
    * use hb_verBuildDate() instead of __DATE__ and __TIME__ in
      hb_verBuildInfo() function to report the same time in both
      cases.
2008-09-22 00:34:52 +00:00
Przemyslaw Czerpak
54252ca860 2008-09-18 17:24 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/make_rpm.sh
    * use rpm to test if curl-devel package is installed

  * harbour/include/hbapi.h
  * harbour/source/common/hbstr.c
    + added hb_strduptrim() and hb_strlentrim()

  * harbour/source/rdd/dbfcdx/dbfcdx1.c
    ! control total length of KEY and FOR expression together
      to be compatible with other CDX drivers.
      Total length of both expressions cannot exceed 512 bytes
      (with two trailing ASCII 0 characters)
2008-09-18 15:25:37 +00:00
Przemyslaw Czerpak
86333ba271 2008-09-18 07:21 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbthread.h
    * use assembler version of atomic inc/dec operation in all x86 based
      GCC builds - it should noticeable improve OS2 MT build speed,
      please test.

  * harbour/include/hbcomp.h
  * harbour/include/hbapicdp.h
  * harbour/include/hbcompdf.h
  * harbour/include/hbgtcore.h
  * harbour/include/hbapifs.h
  * harbour/include/hbwince.h
  * harbour/include/hbexpra.c
  * harbour/include/hbexprop.h
  * harbour/include/hbmacro.h
  * harbour/include/hbapigt.h
  * harbour/include/hbapi.h
  * harbour/include/hbapiitm.h
  * harbour/include/hbexprb.c
  * harbour/source/pp/ppcore.c
  * harbour/source/pp/hbpp.c
  * harbour/source/vm/macro.c
  * harbour/source/vm/cmdarg.c
  * harbour/source/vm/arrays.c
  * harbour/source/vm/extrap.c
  * harbour/source/vm/memvars.c
  * harbour/source/vm/eval.c
  * harbour/source/vm/extend.c
  * harbour/source/vm/set.c
  * harbour/source/main/harbour.c
  * harbour/source/common/hbfsapi.c
  * harbour/source/common/reserved.c
  * harbour/source/common/expropt1.c
  * harbour/source/macro/macro.yyc
  * harbour/source/macro/macro.y
  * harbour/source/macro/macro.yyh
  * harbour/source/macro/macrolex.c
  * harbour/source/rtl/gtdos/gtdos.c
  * harbour/source/rtl/gtwin/gtwin.c
  * harbour/source/rtl/gtxwc/gtxwc.c
  * harbour/source/rtl/gtos2/gtos2.c
  * harbour/source/rtl/hbgtcore.c
  * harbour/source/rtl/cdpapi.c
  * harbour/source/rtl/gtcrs/gtcrs.c
  * harbour/source/rtl/hbtoken.c
  * harbour/source/rtl/gtchrmap.c
  * harbour/source/rtl/gtstd/gtstd.c
  * harbour/source/rtl/gtsln/mousesln.c
  * harbour/source/rtl/gtsln/gtsln.c
  * harbour/source/rtl/gtsln/kbsln.c
  * harbour/source/rtl/gttrm/gttrm.c
  * harbour/source/rtl/gtpca/gtpca.c
  * harbour/source/rtl/hbhex.c
  * harbour/source/rtl/gtgui/gtgui.c
  * harbour/source/rtl/gt_tpl/gt_tpl.c
  * harbour/source/rtl/gtcgi/gtcgi.c
  * harbour/source/rtl/gtwvt/gtwvt.c
  * harbour/source/rtl/strtran.c
  * harbour/source/rtl/hbinet.c
  * harbour/source/rtl/gtapi.c
  * harbour/source/rtl/filesys.c
  * harbour/source/rdd/dbfntx/dbfntx1.c
  * harbour/source/rdd/dbsql.c
  * harbour/source/rdd/dbfcdx/dbfcdx1.c
  * harbour/source/rdd/dbffpt/dbffpt1.c
  * harbour/source/rdd/hbsix/sxfname.c
  * harbour/source/compiler/ppcomp.c
  * harbour/source/compiler/hbmain.c
  * harbour/source/compiler/cmdcheck.c
  * harbour/source/compiler/hbdbginf.c
  * harbour/source/compiler/genc.c
  * harbour/source/compiler/hbident.c
  * harbour/source/compiler/hbusage.c
  * harbour/source/compiler/gencc.c
  * harbour/source/compiler/harbour.yyc
  * harbour/source/compiler/harbour.y
  * harbour/contrib/gtalleg/gtalleg.c
  * harbour/contrib/hbct/charlist.c
  * harbour/contrib/hbct/charmix.c
  * harbour/contrib/hbct/screen1.c
  * harbour/contrib/hbct/atrepl.c
  * harbour/contrib/xhb/hboutdbg.c
  * harbour/contrib/xhb/hbxml.c
  * harbour/contrib/xhb/hbxml.h
  * harbour/contrib/hbgt/strexpan.c
  * harbour/contrib/hbsqlit3/sqlite3/sqlite3.c
  * harbour/contrib/gtwvg/gtwvg.c
  * harbour/contrib/hbclipsm/status.c
  * harbour/contrib/hbclipsm/gauge.c
  * harbour/contrib/hbmisc/stringsx.c
  * harbour/contrib/hbtip/utils.c
  * harbour/contrib/hbgf/hbgfgtk/msginfo.c
  * harbour/contrib/hbgf/hbgfgtk/harbgtk.h
  * harbour/contrib/hbbmcdx/bmdbfcdx.c
  * harbour/utils/hbmake/hbmgauge.c
    * use const char * instead of char * in places which should be marked
      as const
2008-09-18 05:23:49 +00:00
Viktor Szakats
82ac6e7cc6 2008-09-15 01:00 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbverdsp.c
    * Undone prev change.
2008-09-14 23:04:00 +00:00
Viktor Szakats
8e7057547b 2008-09-14 22:36 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbverdsp.c
    + Showing MT status on //BUILD screen.

  * contrib/hbvpdf/hbvpdf.prg
    ! Fix to previous modification (fixing bookmarks).
2008-09-14 20:44:42 +00:00
Viktor Szakats
f093f8045b 2008-09-14 17:59 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
+ contrib/hbnf/tests/nftest.prg
    + Adapted hbnf test program from xhb.

  * contrib/hbnf/common.mak
    ! File list synced with the GNU-make one.
      [TOMERGE 1.0]

  * source/common/hbver.c
    * "Intl." removed from the version number. Besides mimicing 
      CA-Cl*pper there is not point in including this, since 
      all Harbour compilers are by default international version.
2008-09-14 16:00:27 +00:00
Przemyslaw Czerpak
64f97582d9 2008-09-13 18:49 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbpp.h
  * harbour/include/hbvm.h
  * harbour/include/hbcomp.h
  * harbour/include/hbcompdf.h
  * harbour/include/hbtrace.h
  * harbour/include/hbapilng.h
  * harbour/include/hbinit.h
  * harbour/source/rtl/langapi.c
  * harbour/source/pp/ppcore.c
  * harbour/source/pp/hbpp.c
  * harbour/source/vm/itemapi.c
  * harbour/source/vm/hvm.c
  * harbour/source/common/hbver.c
  * harbour/source/common/hbtrace.c
  * harbour/source/common/expropt2.c
  * harbour/source/compiler/complex.c
  * harbour/source/compiler/hbident.c
  * harbour/source/compiler/hbfunchk.c
    * changed some declarations from 'char *' to 'const char *' and
      fixed casting for some more pedantic compilers

  * harbour/source/pp/ppcore.c
    ! fixed one typo which could cause memory leak and even GPF

  * harbour/common.mak
  * harbour/source/vm/Makefile
  * harbour/source/rtl/Makefile
  - harbour/source/rtl/set.c
  + harbour/source/vm/set.c
  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
    * moved from RTL to HVM
    * eliminated hb_set global structure
    * moved set structure to HVM stack
    + added internal function hb_setClone() which is used to create
      copy of SET structure for child threads
    * hidden HB_SET_STRUCT declaration - 3-rd part code must not access it
      directly. Dedicated hb_set*() functions should be used instead.
    + added new function:
         BOOL hb_setSetItem( HB_set_enum set_specifier, PHB_ITEM pItem )
      which allow to change some set by 3-rd party code.
      TODO: not all SETs can be changed yet - if someone have a while
            then please add code for missing ones.

  * harbour/include/set.ch
  * harbour/include/hbset.h
    + added _SET_CODEPAGE which works like _SET_LANGUAGE giving common
      interface

  * harbour/include/hbsetup.h
    + added HB_CODEPAGE_DEFAULT which works like HB_LANG_DEFAULT

  * harbour/source/vm/hvm.c
    ! fixed builds which uses non EN lang or code page modules
      by forcing linking the chosen ones

  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
  * harbour/include/hbapicdp.h
  * harbour/source/rtl/cdpapi.c
    - removed global code page variable: hb_cdp_page and moved
      code page settings to HVM stack
    + added new function hb_cdpID() which returns current code page
      character ID
    + added new functions hb_vmCDP() and hb_vmSetCDP() to get/set
      active for given thread code page structure

  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
  * harbour/include/hbapilng.h
  * harbour/source/rtl/langapi.c
    + moved lang setting to HVM stack
    + added new functions hb_vmLang() and hb_vmSetLang() to get/set
      active for given thread language module

  * harbour/include/hbvmpub.h
  * harbour/include/hbstack.h
  * harbour/include/hbapi.h
  * harbour/source/vm/estack.c
  * harbour/source/vm/dynsym.c
  * harbour/source/vm/itemapi.c
  * harbour/source/vm/memvars.c
    * changed memvar handles for HB_HANDLE to void * which is directly
      casted to PHB_ITEM - new memvar references
    * changed HB_DYNS declarations for MT mode. In MT mode HB_DYNS does
      not contain area and memvar handles which are moved to thread
      local HVM stack
    + added array for thread local memvar and area handles to HVM stack
    % eliminated global continues array with all memvars and detached locals
    % changed HB_IT_MEMVAR to use pointers to HB_ITEM directly - it resolve
      synchronization problems in MT mode and should also improve the speed
      and reduce memory usage. It should be well visible in applications which
      uses lot of detached locals.
    - removed hb_memvarsInit() and hb_memvarsFree() - they are not necessary
      now because we do not longer use array with all allocated memvars
      and detached local and private stack initialization is made
      automatically
    + added internal functions hb_dynsymGetMemvar()/hb_dynsymSetMemvar()
    + added hb_memvarGetValueBySym() for debugger
    * moved PRIVATE variable stack to HVM stack
    * eliminated all static variables in memvars module

  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
  * harbour/source/rtl/fserror.c
    * moved IO errors to HVM stack
    + added special IO error handling which works without HVM stack
      It allows to use hb_fs*() functions without allocated stack
      by 3-rd party threads.

  * harbour/source/rtl/filesys.c
    * moved hb_fsCurDir() to HVM stack with special handling to work
      with HVM stack like IO errors

  * harbour/source/rdd/workarea.c
    * allocated RDD node array in bigger peaces to reduce later RT
      reallocations in MT mode. If user want to add dynamically more
      then 64 RDDs then it should synchronize this operation himself.

  * harbour/source/rdd/wacore.c
    * moved WA list, current WA, default RDD and neteer() flag to HVM stack

  * harbour/include/hbdefs.h
    - removed HB_HANDLE declaration

  * harbour/include/hbapi.h
    - removed HB_VALUE structure - it's not longer used due to different
      memvar handling
    * updated hb_struMemvar to new memvar handling
    * replaced hb_vmIsLocalRef() and hb_memvarsIsMemvarRef() with
      hb_vmIsStackRef() which respect multiple stack and new memvar
      and static structures and location in GC mark pass.

  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
  * harbour/source/vm/hvm.c
    + added support for thread specific data located on HVM stack
      Now it's possible to allocate static variables which are
      local to thread. Such variables are allocated on HVM stack
      and automatically destroyed. To declare new TSD variable use:
         HB_TSD_NEW( <name>, <size>, <init>, <destruct> )
      <name> - name of variable which holds TSD handler
      <size> - size of TSD are which has to be allocated
      <init> - init function, executed when new TSD is allocated by thread
               (thread access given TSD 1-st time). This function receives
               void * pointer to allocated area.
      <destruct> - destructor function executed when HVM stack is destroyed
      f.e.:
         static HB_TSD_NEW( s_scrData, sizeof( HB_SCRDATA ),
                            NULL, hb_xSaveRestRelease );
      To initialize dynamically allocated TSD variable use:
         HB_TSD_INIT( <name>, <size>, <init>, <destruct> )
      Pointer to TSD can be accessed using hb_stackGetTSD( &<name> )
      where <name> is name of variable which holds TSD handler, f.e.:
         PHB_SCRDATA pScrData = ( PHB_SCRDATA ) hb_stackGetTSD( &s_scrData );
      See source/rtl/xsavescr.c as an example
      It's also possible to test if data has been already allocated for
      current thread by:
         hb_stackTestTSD( &<name> ) => pData
      it works like hb_stackGetTSD() but return NULL if current thread data
      has not been allocated yet.

  * harbour/include/hbstack.h
  * harbour/source/vm/estack.c
    * changed hb_stack location to thread local storage in MT mode
    + added functions and macros to access/assign new HVM stack members
    + changed garbage collection mark functions to work with multiple
      stacks, thread local static and memvar variables

  * harbour/source/rtl/xsavescr.c
    * use TSD data for screen buffer to make __XSAVESCREEN()/__XRESTSCREEN()
      thread independent

  * harbour/source/rtl/idle.c
    * use TSD data for idle task settings and codeblocks
    - removed hb_idleShutDown() - it's not longer necessary

  * harbour/source/rtl/setkey.c
    * use TSD data for allocated keys to make SETKEY() thread independent

  * harbour/source/rtl/math.c
    * moved math error handler, math error block, math error mode and
      math error structure to TSD

  * harbour/source/rtl/errorapi.c
    * moved error handler, error block, error launch counter and DOS error
      value to TSD

  * harbour/source/rtl/inkey.c
    * moved inkey "before" and "after" blocks to TSD

  * harbour/source/rdd/hsx/hsx.c
    * moved HSX handles array to TSD

  * harbour/include/hbapigt.h
  * harbour/source/rtl/console.c
    - removed hb_setkeyInit() and hb_setkeyExit() - they are not longer
      necessary, allocated resources will be freed by TSD destructor
      function

  * harbour/include/hbapi.h
  * harbour/source/rtl/console.c
    * removed hb_conXSaveRestRelease() - it's not longer necessary,
      allocated resources will be freed by TSD destructor function

  * harbour/source/vm/macro.c
    * moved s_macroFlags to TSD

  * harbour/source/rtl/accept.c
    * moved accept buffer to TSD

  * harbour/include/hbcomp.h
  * harbour/include/hbcompdf.h
  * harbour/include/hbxvm.h
  * harbour/source/compiler/hbmain.c
  * harbour/source/compiler/hbfix.c
  * harbour/source/compiler/hbpcode.c
  * harbour/source/compiler/hbdead.c
  * harbour/source/compiler/complex.c
  * harbour/source/compiler/genc.c
  * harbour/source/compiler/gencc.c
  * harbour/source/compiler/hbopt.c
  * harbour/source/compiler/hblbl.c
  * harbour/source/compiler/hbstripl.c
  * harbour/source/compiler/harbour.y
  * harbour/source/compiler/harbour.yyc
  * harbour/source/compiler/harbour.yyh
  * harbour/source/vm/hvm.c
    + added new PCODE HB_P_THREADSTATICS
    + added support for static variables which are local to thread:
         THREAD STATIC <varname [:= <exp>], ...>
      They work like normal static variables but each thread operates
      on its own copy.
    * added protection against possible double call to hb_xfree()
      It can happen due to wrong marking expressions as used by bison
      and executing destructors after our free code when syntax error
      appear.

  * harbour/source/rtl/perfuncs.prg
  * harbour/source/rtl/menuto.prg
  * harbour/source/rtl/getlist.prg
  * harbour/source/rtl/readvar.prg
  * harbour/source/rtl/text.prg
    * use THREAD STATIC variables to make above code MT safe

  * harbour/include/hbgtcore.h
  * harbour/source/rtl/hbgtcore.c
    + added hb_gt_BaseFree() which will release current GT pointer
      locked by hb_gt_Base() function. This function will be used
      to optional automatic GT access synchronization when threads
      share the same GT.

  * harbour/source/rtl/gtapi.c
  * harbour/source/rtl/inkeyapi.c
  * harbour/source/rtl/mouseapi.c
  * harbour/contrib/hbct/ctwin.c
    * free GT pointer by hb_gt_BaseFree()
      TODO: CTWIN is not MT safe yet - it will be updated together
            with core GT when we add multi window interface for
            thread with own console window.

  * harbour/bin/hb-func.sh
  * harbour/config/linux/gcc.cf
    + added rt lib to Linux builds

  * harbour/bin/postinst.sh
    * create MT safe version of FM stat library: fmmt

  * harbour/bin/pack_src.sh
    + added support for ZIP packing

  * harbour/include/hbapi.h
  * harbour/include/hbvm.h
  * harbour/source/vm/hvm.c
    + added hb_vmThreadInit()/hb_vmThreadQuit() functions - they initialize
      HVM for calling thread so it can execute .prg code and call HVM
      functions. They can be used by 3-rd party code threads.
    + added hb_vmUnlock()/hb_vmLock() functions which informs that
      thread will not operate on HVM structures for some time allowing
      to execute single thread only processes like GC.
    + added hb_vmThreadQuitRequest() which sends stop request to given
       thread
    + added hb_vmWaitForThreads() which stops main thread execution waiting
      for other threads
    + added hb_vmSuspendThreads() and hb_vmResumeThreads() used be GC
      to stop all HVM threads before mark/swap scan
    + added linked list of HVM stacks
    + added hb_vmTerminateThreads() used by main HVM thread in QUIT state
    * moved EXIT procedures execution from QUIT request to HVM QUIT state
      in MT mode. It may effects some non structural code which tries to
      access private variables in EXIT functions but it's much cleaner
      and understandable for user. Please remember that we guaranties
      that ALWAYS code in BEGIN SEQUENCE is _always_ executed even after
      HVM QUIT request just like destructs. Personally I think that we
      should move EXIT procedures execution also in ST mode.
    * changed startup and cleanup code for new internal structures
    * changes startup and cleanup code for MT mode
    % removed some redundant HB_ITEM type settings
    ! eliminated non MT safe code which was using reference counters
      without protection

  * harbour/common.mak
  * harbour/source/vm/Makefile
  + harbour/include/hbthread.h
  + harbour/source/vm/thread.c
    + added C level functions to manage threads and synchronization objects
      See hbthread.h for detail description. They are based on PTHREAD API
      and PTHREAD documentation can be used as reference. I intentionally
      keep this list small for easier multiplatform porting.
      Now they have been implemented for PTHREADS (POSIX threads supported by
      many different OSes), MS-Win32/64 and OS2. The OS2 version is not tested
      at all. I do not even know if it can be compiled so please make tests.
      I used Internet resources and some part of xHarbour code as documentation
      for OS2 MT API. It should be quite easy to add other platforms if necessary.
      Harbour core code needs non recursive mutexes, conditional variables and
      TLS for one pointer. If platforms does not support conditional variables
      (f.e. MS-Win or OS2) then they can be emulated using multistate semaphores.
    + added .prg functions to manage threads and synchronization objects:
         hb_threadStart( <@sStart()> | <bStart> [, <params,...> ] ) -> <pThID>
         hb_threadJoin( <pThID> [, @<xRetCode> ] ) -> <lOK>
         hb_threadDetach( <pThID> ) -> <lOK>
         hb_threadQuitRequest( <pThID> ) -> <lOK>
         hb_threadWaitForAll() -> NIL
         hb_mutexCreate() -> <pMtx>
         hb_mutexLock( <pMtx> [, <nTimeOut> ] ) -> <lLocked>
         hb_mutexUnlock( <pMtx> ) -> <lOK>
         hb_mutexNotify( <pMtx> [, <xVal>] ) -> NIL
         hb_mutexNotifyAll( <pMtx> [, <xVal>] ) -> NIL
         hb_mutexSubscribe( <pMtx>, [ <nTimeOut> ] [, @<xSubscribed> ] ) -> <lSubscribed>
         hb_mutexSubscribeNow( <pMtx>, [ <nTimeOut> ] [, @<xSubscribed> ] ) -> <lSubscribed>
      The function list should give similar to xHarbour API but they are not exactly
      the same and except of hb_mutex*() functions which should replicate xHarbour behavior.

  + harbour/source/vm/vmmt
  + harbour/source/vm/vmmt/Makefile
    + added hbvmmt library to GNU make builds.
      Non GNU make builds should be updated.

  * harbour/contrib/hbct/pos1.c
  * harbour/contrib/gtwvg/gtwvg.c
  * harbour/contrib/rddads/ads1.c
  * harbour/contrib/hbmisc/spd.c
  * harbour/contrib/hbbmcdx/bmdbfcdx.c
  * harbour/contrib/examples/rdddbt/dbfdbt1.c
  * harbour/source/vm/runner.c
  * harbour/source/vm/itemapi.c
  * harbour/source/vm/hvm.c
  * harbour/source/rtl/console.c
  * harbour/source/rtl/strcase.c
  * harbour/source/rtl/spfiles.c
  * harbour/source/rtl/defpath.c
  * harbour/source/rtl/hbgtcore.c
  * harbour/source/rtl/dateshb.c
  * harbour/source/rtl/mlcfunc.c
  * harbour/source/rtl/fstemp.c
  * harbour/source/rtl/is.c
  * harbour/source/rtl/setcolor.c
  * harbour/source/rtl/errorint.c
  * harbour/source/rtl/transfrm.c
  * harbour/source/rtl/dates.c
  * harbour/source/rtl/filesys.c
  * harbour/source/rtl/gtdos/gtdos.c
  * harbour/source/rtl/gtwin/gtwin.c
  * harbour/source/rtl/gtwvt/gtwvt.c
  * harbour/source/rtl/gtxwc/gtxwc.c
  * harbour/source/rtl/gttrm/gttrm.c
  * harbour/source/rtl/gtpca/gtpca.c
  * harbour/source/rtl/gtcgi/gtcgi.c
  * harbour/source/rtl/gtcrs/gtcrs.c
  * harbour/source/rtl/gtstd/gtstd.c
  * harbour/source/rtl/gtsln/gtsln.c
  * harbour/source/rtl/gtsln/gtsln.h
  * harbour/source/rdd/dbf1.c
  * harbour/source/rdd/sdf1.c
  * harbour/source/rdd/delim1.c
  * harbour/source/rdd/dbcmd.c
  * harbour/source/rdd/hbdbsort.c
  * harbour/source/rdd/workarea.c
  * harbour/source/rdd/dbffpt/dbffpt1.c
  * harbour/source/rdd/dbfcdx/dbfcdx1.c
  * harbour/source/rdd/dbfntx/dbfntx1.c
  * harbour/source/rdd/hsx/hsx.c
  * harbour/source/rdd/hbsix/sxfname.c
    * use API functions instead of direct accessing to hb_cdp_page or hb_set

  * harbour/source/rtl/fstemp.c
  * harbour/source/rtl/fssize.c
  * harbour/source/rtl/hbffind.c
  * harbour/source/rtl/filesys.c
    * encapsulate potentially slow IO operation inside
      hb_vmUnlock()/hb_vmLock() calls to allow other thread GC
      activation

  * harbour/contrib/hbnf/fttext.c
    ! fixed casting

  * harbour/contrib/gtwvg/gtwvg.h
    - removed #include <comctl32.h> - my MinGW and MinGW/CE instalations do
      not have them. If it exists in some newer ones then it has to be
      covered by #if version checking.

  * harbour/source/vm/dynsym.c
    - removed hb_dynsymLog() and hb_dynsymMemvarHandle()
    * modified code to be MT safe and improved speed of some operations
    * added MUEXT protection for global dynamic table access

  * harbour/include/hbapi.h
  * harbour/source/vm/garbage.c
    * changed to work with MT HVM
    * changed to work with new memvar structures and thread local static and
      memvar variables
    * added MUEXT protection for linked block lists
    + added parameter to hb_gcCollectAll() which will force GC activation
      in MT mode by temporary suspending all executed threads.
    + added logical parameter to HB_GCALL() functions which is passed to
      hb_gcCollectAll()

  * harbour/source/vm/fm.c
    * added MUEXT protection for FM statistic module
    * added MT protection for reference counters. For platforms
      which supports atomic incrmenetation/decrementation (f.e.
      Interlocked*() functions in MS-Win) such operations are
      used. For other it's MUTEX protection. It gives MT safe
      readonly access for HVM complex variables without user
      synchronization. The MUTEX protection can cause some speed
      overhead so it's good to define MT safe version of
      HB_ATOM_INC()/HB_ATOM_DEC() in hbthread.h if given platform
      has them. Now they are defined only for Windows. For other
      platforms We can define can define them in assembler for some
      most popular CPUs in the future.

  * harbour/source/vm/classes.c
    * changed class definition array. Now it keeps pointers to class
      structures.
    * In MT mode allocated at HVM startup big enough array for class
      definitions to avoid later RT reallocations. It effectively eliminates
      MUTEX synchronization for class structure access.
    * protect by MUTEX code for new class creation

  * harbour/source/debug/dbgentry.c
    * eliminated hbvmopt.h and direct accessing to HVM structures

  * harbour/source/rtl/gtclip.c
    * protect with MUTEX access to internal clipboard data

  * harbour/source/rdd/nulsys/nulsys.c
    + added hb_rddCloseAll()

  + harbour/tests/mt
  + harbour/tests/mt/mttest01.prg
  + harbour/tests/mt/mttest02.prg
  + harbour/tests/mt/mttest03.prg
  + harbour/tests/mt/mttest04.prg
  + harbour/tests/mt/mttest05.prg
  + harbour/tests/mt/mttest06.prg
  + harbour/tests/mt/mttest07.prg
    + added some demonstration/test small MT programs written
      using Harbour language. Some of them can be also compiled
      by xHarbour but xHarbour does not pass any of my tests in
      real multi-CPU machine so do not expect they will work
      correctly.

   Harbour threads needs OS threads support. Each Harbour thread is directly
   mapped to OS thread. It's not very efficient on some older system where
   cost of thread creation and/or task switching is very expensive but it
   should not be bigger problem for modern OS-es which can support threads
   in practice nearly in user space only.
   I haven't touched Harbour function calling convention which comes from
   Clipper. It means that we do not pass pointer to VM to each functions
   like CLIP or xBase++. To resolve the problem I have to use thread local
   storage (TLS) where such pointer is kept. If platform does not support
   TLS then it can be emulated by us. Anyhow the speed of accessing TLS
   data and extracting HB_STACK poitner is critical for performance.
   Some compilers depending on used hardware and OS give native support
   for TLS (f.e. __thread keyword in GCC/BCC or __declspec( thread ) in MSVC).
   This should give optimal performance. On other Harbour uses TLS functions
   like TlsGetValue() (MS-WIN) or pthread_getspecific() (PTHREAD) are used.
   OS2 gives quite interesting TLS functionality which seems to be quite fast
   though it will be interesting to know how it is iplemented internally for
   real multi CPU machines (if it depends on CPU exception then the
   performance will be bad). We need TLS only for one pointer to HB_STACK
   structure.
   I haven't added any tricks like HB_THREAD_STUB in xHarbour to reduce
   the cost of TLS access. If it will be necessary for some platform the we
   can add it.
   Except TLS Harbour threads needs OS support for non recursive mutexes or
   critical sections and conditional variables. If platforms does not support
   conditional variables (f.e. MS-Win or OS2) then they can be emulated using
   multistate semaphores. I intentionally didn't create code which may need
   recursive mutexes. The non recursive ones are often faster and some
   platforms may not support recursive mutexes so they will have to be
   emulated by us.
   Harbour uses reference counters for complex variables. It means that even
   readonly access to complex item causes internal write operations necessary
   to increment/decrement its reference counter. To make such readonly access
   MT safe we have to make incrementation and decrementation with result
   checking atomic. By default it's done by mutex inside vm/fm.c but some
   platforms have native support for atomic inc/dec operations, f.e. 
   Interlocked*() functions in MS-Win. If they are available then such
   functions should be used to not reduce the performance by mutex call
   very often used functions. For many CPUs it should be quite easy to
   implement such atomic inc/dec functionality in assembler. F.e. for
   GCC and x86@32 it may looks like:

      static __inline__ void hb_atomic_inc32( volatile int * p )
      {
         __asm__ __volatile__(
            "lock incl %0"
            :"=m" (*p) :"m" (*p)
         );
      }

      static __inline__ int hb_atomic_dec32( volatile int * p )
      {
         unsigned char c;
         __asm__ __volatile__(
            "lock decl %0"
            "sete %1"
            :"=m" (*p), "=qm" (c) :"m" (*p) : "memory"
         );
         return c == 0;
      }

   and then it's enough to define in hbthreads.h:
      #define HB_ATOM_INC( p )    hb_atomic_inc32( ( volatile int * ) p )
      #define HB_ATOM_DEC( p )    hb_atomic_dec32( ( volatile int * ) p )

   Probably I'll make it for some most popular CPUs in the future.
   In Harbour each thread which wants to call HVM functions have to allocate
   it's own HVM stack. It's done hb_vmThreadInit(). The HVM stack is freed
   by calling hb_vmThreadQuit(). This functions can be called also by 3-rd
   party threads if they want to call HVM functions or execute .prg code.
   Calling HVM functions without allocated stack will cause GPF.
   I moved most of static variables to HVM stack to make them thread
   local. But some of them like FS errors have their own alternative
   copy which is used when thread does not allocate HVM stack. It allows
   to use hb_fs*() functions without HVM stack but programmer have to
   know that error codes return by hb_fs*Error() functions can be
   overwritten by other threads which also didn't allocated HVM stack.
   To execute garbage collector scan and mark pass it's necessary to
   stop other HVM threads. Otherwise the scan may give false results.
   It's also possible to not stop threads but protect with mutex all
   operations on GC items but it will probably cause performance reduction
   and will force some other modifications. Maybe I'll implement it
   in the future.
   I didn't use any OS level thread KILL or CANCEL calls. All HVM threads
   have to be cleanly removed without any resource leaks.
   QUIT command terminate only calling thread. If main (startup) HVM
   thread call QUIT then it sends QUIT request to all existing threads.
   In QUIT state ALWAYS statements and destructors are executed.
   New thread is created by:
      hb_threadStart( <@sStart()> | <bStart> [, <params,...> ] ) -> <pThID>
   The returned value is a pointer to internal thread structure which
   can be used in JOIN or DETACH operations. Each thread should be Joined
   or DETACHED to avoid resource leaks. If programmer does not store
   <pThID> or all instances of <pThID> are destroyed then thread is
   automatically detached. I do not know clear method of thread detaching
   in OS2. If some OS2 users knows it then plase update vm/hbthread.c.
   When thread terminates then all locked by this thread mutexes are
   released.
   Each thread uses its own memvars (PRIVATEs and PUBLICs) and work areas.
   When new thread is created then it inherits from parent thread:
      - code page
      - language
      - SETs
      - default RDD
   error block is initialized to default value by calling ERRORSYS()
   and PUBLIC variable GetList := {} is created.
   The following objects are initialized to default value:
         - error block
         - math error handler and math error block
         - macro compiler features setting (hb_setMacro())
           or move them to SETs.
   We can think about inheriting them. It's also possible to add
   inheriting of all visible memvars but I do not know it's good
   idea.

   Compilation and linking:
   For MT mode HVM library should be compiled with HB_MT_VM macro.
   GNU make automatically creates hbvmmt library which should be
   linked with Harbour MT programs instead of hbvm.
   Non GNU make files should be updated.
   If given compiler support TLS then you can try to set HB_USE_TLS
   to force using native compiler TLS support. Now it's enabled by
   default only for BCC. For Linux and GCC builds it may depend also
   on used GLIBC version. In older system there is no TLS support
   at all or TLS works only for shared binaries so I haven't enabled
   it. If you will test some other compiler then please add default
   native TLS support for them in hbthread.h
   Users using hb* scripts can simply use -mt switch when they want
   to create MT program, f.e.:
      hbmk -n -w3 -es2 -mt mttest01.prg

   There are still some minor things which should be done but I'll
   do them later. Current state seems to be fully functional.
   The most important and still missing is our own file lock server
   for RDD synchronization in POSIX systems. Kernel internally
   recognize POSIX locks by PID and file i-node - not PID and file
   handle. It means that the same file open more then once by one
   process shares locks. Because POSIX locks can be overwritten
   then we do not have any synchronization between aliased workareas
   or threads using the same table in *nixes. We have to make
   synchronization ourselves. I'll create such lock server ASAP.

   Please test and enjoy using Harbour threads.
2008-09-13 16:53:45 +00:00
Viktor Szakats
d21af17b6d 2008-09-05 12:01 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbver.c
     ! Version detection fixed for __DMC__
       [TOMERGE 1.0.1]

   * contrib/mtpl_gcc.mak
     % One unnecessary C -I option deleted.
       [TOMERGE 1.0.1]

   - contrib/hbsqlit2
   + contrib/examples/hbsqlit2
   * doc/whatsnew.txt
     * Moved hbsqlit2 to examples.
       [TOMERGE 1.0.1]

   * contrib/examples/hbsqlit2/Makefile
   * contrib/examples/hbsqlit2/make_b32.bat
   * contrib/examples/hbsqlit2/make_gcc.sh
   * contrib/examples/hbsqlit2/make_vc.bat
   * contrib/examples/hbsqlit2/common.mak
   * contrib/examples/hbsqlit2/tests/bld_b32.bat
   * contrib/examples/hbsqlit2/tests/bld_vc.bat
     * Modified make files to work from the new location.
     * Location of sqlite2 headers can be specified by HB_INC_SQLITE2.
     ; Notice that sqlite2 lib itself should now be build separately.
       [TOMERGE 1.0.1]
2008-09-05 10:04:58 +00:00
Viktor Szakats
b7b03486a4 2008-08-29 10:35 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* ChangeLog
     ! Minor typo.

   * utils/hbmake/hbmake.prg
     % Minor cleanup.

   * source/common/hbver.c
     * Further cleanup of constant usage.
     + Changed Borland to CodeGear to BCC5.9 and above.
       (borrowed from xhb / Andi Jahja)

   * config/w32/gcc.cf
   * config/w32/dm.cf
     * contrib syslibs moved to separate lines.
2008-08-29 08:37:04 +00:00
Viktor Szakats
d2f974642f 2008-08-26 22:13 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbver.c
     * hb_verCompiler() buffer size cleanup.

   * source/rtl/hbinet.c
     * Minor formatting.

   * utils/hbmake/hbmake.prg
     * PRG -> .prg on some screen messages.

   * config/w32/xcc.cf
   * config/w32/pocc.cf
     + Added ws2_32.lib. Didn't solve the problem, but 
       as per MS docs of some functions we use, we should 
       use this instead of wsock2 (everywhere actually) 
       [and ws2 instead of winsock for WinCE]. Someone pls 
       correct me if I'm wrong, or if there is any reason 
       we're using both and/or the older one?

   * config/w32/pocc.cf
     - Removed C switch -Zx (Enable Pelles C extensions).
       We don't need this.
2008-08-26 20:15:41 +00:00
Viktor Szakats
2cce45bb1c 2008-08-26 15:14 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbver.c
     + Show bitness for all (non-DJGPP) compilers.
     ! Fixed to show "Windows Server 2003 / XP x64" when 
       Windows 5.2 is detected.
2008-08-26 13:15:04 +00:00
Viktor Szakats
7eedaf89c6 2008-08-25 22:35 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* include/hbsetup.h
   * source/common/hbver.c
     - Removed HB_OS_MAC support. It was nothing more than a simple
       detection and a static version string, so we didn't lose much.
2008-08-25 20:36:31 +00:00
Viktor Szakats
7ecef08518 2008-08-25 18:28 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbver.c
     ! Fix to commit '2008-07-11 18:20 UTC+0200' which 
       effectively disabled Vista/2008 detection for 
       everything but MSVC (>1400) compilers.
2008-08-25 16:29:01 +00:00
Viktor Szakats
55ae11bfcd 2008-08-24 13:15 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/vm/runner.c
   * source/vm/fm.c
   * source/common/hbver.c
   * source/rtl/hbgtcore.c
   * source/rtl/gtwvt/gtwvt.c
   * source/rdd/dbfntx/dbfntx1.c
   * source/rdd/workarea.c
   * source/rdd/wacore.c
   * source/rdd/sdf1.c
   * source/rdd/dbfcdx/dbfcdx1.c
   * source/rdd/delim1.c
   * source/rdd/dbf1.c
   * source/rdd/wafunc.c
   * source/rdd/dbffpt/dbffpt1.c
   * source/compiler/hbmain.c
   * source/compiler/fixflex.c
   * source/compiler/gencobj.c
   * source/compiler/genc.c
   * source/compiler/harbour.yyc
   * source/compiler/harbour.y
   * contrib/hbct/disk.c
   * contrib/hbwhat32/whtcdlg.c
   * contrib/gtwvg/gtwvg.c
   * contrib/rddads/adsfunc.c
   * contrib/rddads/ads1.c
   * contrib/hbbmcdx/bmdbfcdx.c
   * contrib/examples/pp/hbppcomp.c
     * hb_strncpy()/hb_strncat() size parameter changed from 
       CONSTANT to 'sizeof( dest ) - 1', where applicable.
     ! hbct/VOLUME() buffer overrun fixed.
     ; NOTE: dbfntx1.c has a couple of places where I wasn't 
             sure of the intention, so I left them unchanged.
2008-08-24 11:21:08 +00:00
Viktor Szakats
647a4ec957 2008-08-23 19:00 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/common/hbwince.c
     ! strcpy() -> hb_strncpy()
     ; TOFIX: Only spd.c and dbgentry.c have some remaining strcpy() 
              calls.
2008-08-23 17:01:47 +00:00
Viktor Szakats
3a41ed1d2b 2008-08-17 08:59 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* doc/dirstruc.txt
     * Updated to reflect current state. [Chen Kedem]

   * contrib/examples/pp/hbppcore.c
   * contrib/examples/pp/pp.c
   * contrib/hbct/disk.c
   * contrib/hbct/files.c
   * contrib/hbnf/getenvrn.c
   * contrib/hbw32/tprinter.c
   * contrib/hbziparch/hbxdirec.c
   * contrib/hbziparch/hbziparc.c
   * contrib/rddads/ads1.c
   * contrib/rddads/adsfunc.c
   * doc/en/terminal.txt
   * include/hb_io.h
   * include/hbapifs.h
   * include/hbapirdd.h
   * include/hbdefs.h
   * include/hbsetup.h
   * include/hbwince.h
   * source/common/hbfsapi.c
   * source/compiler/gencobj.c
   * source/compiler/hbcomp.c
   * source/compiler/hbusage.c
   * source/debug/dbgentry.c
   * source/main/harbour.c
   * source/pp/hbpp.c
   * source/pp/ppcore.c
   * source/rdd/dbcmd.c
   * source/rdd/dbf1.c
   * source/rdd/delim1.c
   * source/rdd/sdf1.c
   * source/rdd/usrrdd/usrrdd.c
   * source/rdd/wacore.c
   * source/rdd/wafunc.c
   * source/rdd/workarea.c
   * source/rtl/console.c
   * source/rtl/copyfile.c
   * source/rtl/defpath.c
   * source/rtl/direct.c
   * source/rtl/disksphb.c
   * source/rtl/file.c
   * source/rtl/filesys.c
   * source/rtl/fssize.c
   * source/rtl/fstemp.c
   * source/rtl/gtos2/gtos2.c
   * source/rtl/gtpca/gtpca.c
   * source/rtl/gtstd/gtstd.c
   * source/rtl/gttrm/gttrm.c
   * source/rtl/hbffind.c
   * source/rtl/hbinet.c
   * source/rtl/memofile.c
   * source/rtl/philes.c
   * source/rtl/seconds.c
   * source/rtl/set.c
   * source/vm/hvm.c
   * source/vm/main.c
     * Changed some macros to be in the HB_ namespace, to be 
       possibly shorter, more unified and clearer.
       OS_UNIX_COMPATIBLE                -> HB_OS_UNIX_COMPATIBLE
       OS_PATH_LIST_SEPARATOR            -> HB_OS_PATH_LIST_SEP_CHR
       OS_PATH_DELIMITER                 -> HB_OS_PATH_DELIM_CHR
       OS_PATH_DELIMITER_STRING          -> HB_OS_PATH_DELIM_STR
       OS_PATH_DELIMITER_LIST            -> HB_OS_PATH_DELIM_LIST
       OS_FILE_MASK                      -> HB_OS_ALLFILE_MASK
       OS_DRIVE_DELIMITER                -> HB_OS_DRIVE_DELIM_CHR
       OS_HAS_DRIVE_LETTER               -> HB_OS_HAS_DRIVE_LETTER
       OS_OPT_DELIMITER_LIST             -> HB_OS_OPT_DELIM_LIST
       OS_EOL_LEN                        -> HB_OS_EOL_LEN
       HARBOUR_GCC_OS2                   -> HB_OS_OS2_GCC
       HARBOUR_START_PROCEDURE           -> HB_START_PROCEDURE
       HARBOUR_MAIN_STD                  -> HB_MAIN_STD
       HARBOUR_MAIN_WIN                  -> HB_MAIN_WIN
       HARBOUR_MAX_RDD_DRIVERNAME_LENGTH -> HB_RDD_MAX_DRIVERNAME_LEN
       HARBOUR_MAX_RDD_ALIAS_LENGTH      -> HB_RDD_MAX_ALIAS_LEN
       HARBOUR_MAX_RDD_AREA_NUM          -> HB_RDD_MAX_AREA_NUM
     ; INCOMPATIBLE change, please update your sources, a simple 
       case-sensitive search and replace on .c/.cpp/.h/.hpp files 
       will be enough for most sources.
2008-08-17 07:39:25 +00:00
Przemyslaw Czerpak
215e18e9bd 2008-08-13 05:30 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/pp/ppcore.c
  * harbour/source/pp/hbpp.c
  * harbour/source/vm/itemapi.c
  * harbour/source/vm/hvm.c
  * harbour/source/common/hbver.c
  * harbour/source/macro/macrolex.c
  * harbour/source/hbpcre/pcrecomp.c
  * harbour/source/compiler/hbpcode.c
  * harbour/contrib/hbmisc/spd.c
  * harbour/contrib/hbsqlit3/sqlite3/sqlite3.c
    * pacified warnings

  * harbour/config/w32/dm.cf
    * updated to work with SHELL env
    - comment -w7 switch
2008-08-13 03:31:00 +00:00
Przemyslaw Czerpak
990ac68465 2008-08-12 22:49 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/config/w32/dm.cf
    * updated for central library directory used by Harbour - not tested

  * harbour/config/w32/xcc.cf
    ! fixed include PATH in XCC builds - Viktor be carefull with
      cleaning -I<path> parameter. Some compilers use different
      rulles then the one you may expect using the most popular
      ones and such operation will break compilation. F.e. XCC
      seems to ignore source file location for releative paths
      so in GNU make builds it's necessary to add "-I$(TOP)"
      instead of "-I." and when included file starts with ".."
      then it does not try to use it with paths set by -I option
      so we need -I$(TOP)$(ROOT) and hard coded for this compiler
      directories in include/hbregex.h and include/hbzip.h

  * harbour/source/hbzlib/zutil.h
    ! do not use fdopen() with XCC - it does not support it

  * harbour/contrib/examples/pp/pp.c
  * harbour/contrib/examples/pp/hbppcore.c
  * harbour/source/common/hbfsapi.c
  * harbour/source/rtl/fnsplit.c
  * harbour/source/rtl/fstemp.c
    ! always use _POSIX_PATH_MAX + 1 buffers

  * harbour/source/compiler/gencobj.c
    * extended line buffer size

  * harbour/source/rtl/gtcrs/gtcrs.h
    * removed unnecessary declaration for _POSIX_PATH_MAX
      it's always defined in Harbour header files

  * harbour/source/rtl/inkey.c
  * harbour/source/rtl/hbinet.c
  * harbour/source/rtl/gtwvt/gtwvt.c
    * use hb_array[SG]et*() functions insteaf of
      hb_item*( hb_arrayGetItemPtr, ... )
2008-08-12 20:50:38 +00:00
Przemyslaw Czerpak
6238ebfb9c 2008-08-10 16:17 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/bin/hb-func.sh
    * updated library list for wince harbour.dll linking

  * harbour/source/common/hbwince.c
    ! fixed compilation new MinGWCE
2008-08-10 14:17:52 +00:00
Przemyslaw Czerpak
770eb9f046 2008-07-23 12:18 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/common/hbwince.c
    * formatting

  * harbour/contrib/hbcurl/hbcurl.c
    + use hash table to keep strings passed to CURL library accessible
      even if HVM destroys them. It should allow to safely use HBCURL
      wrapper also with CURL library older then 7.17.0 though it can
      be a little bit expensive in some cases. The allocated strings
      are freed when CURL pointer is destroyed (directly or by
      CURL_EASY_CLEANUP()) or reset by CURL_EASY_RESET().
      This feature is enabled only when compiled for CURL libraries
      older then 7.17.0 or when user set explicitly compile time macro
      HB_CURL_HASH_STRINGS
      Viktor, you are more familiar with this code so please check it.
2008-07-23 10:19:33 +00:00
Przemyslaw Czerpak
3c31a039ed 2008-07-21 19:05 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbwince.h
    * added DRIVE_UNKNOWN declaration for MSVC WinCE builds

  * harbour/source/common/expropt2.c
    * pacified warning
2008-07-21 17:05:26 +00:00
Przemyslaw Czerpak
3d4a97040b 2008-07-17 18:19 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/contrib/hbw32/dllcall.c
    * minor cleanup in return values

  * harbour/contrib/hbole/ole2.c
    * cleaned casting in UNICODE conversions

  * harbour/source/common/expropt2.c
    * replicate CA-Cl*pper compile time optimization bugs:
         "" $ <literString>         => .T.
         AT( "", <literString> )    => 1
         CHR( 256 )                 => ""
      only when Harbour extensions (-kh) are not enabled, f.e.
      in strict Clipper compatibility mode (-kc)

  * harbour/utils/hbtest/rt_hvma.prg
  * harbour/utils/hbtest/rt_str.prg
    * updated to test Clipper and Harbour compile time modes in
      the above situations

  * harbour/common.mak
  * harbour/source/rtl/Makefile
  - harbour/source/rtl/strings.c
  * harbour/source/common/hbstr.c
    * moved hb_strEmpty() from RTL to COMMON library

  * harbour/include/hbexprb.c
  * harbour/include/hbexprop.h
  * harbour/source/common/expropt2.c
    + added compile time optimization for EMPTY() function
    ; removed 'TODO: empty optimization' note

  * harbour/source/rtl/itemseri.c
    % compress trailing spaces during string item serialization

  * harbour/include/hbapi.h
  * harbour/source/vm/hashes.c
    + added hb_hashAddNew() - works like hb_hashAdd() but it adds item
      only if new key is used

  * harbour/source/vm/hvm.c
    * use hb_hashAddNew() instead of hb_hashAdd() for HB_P_HASHGEN
      I cannot revert the order of hash item during compilation because
      it will also change the order of user expression evaluation.
2008-07-17 16:28:11 +00:00
Jean-Francois Lefebvre
0159cc03e3 2008-07-11 18:20 UTC+0200 JF Lefebvre (MAFACT) (jfl/at/mafact.com) 2008-07-11 16:34:23 +00:00
Przemyslaw Czerpak
d5ecd90c31 2008-07-09 18:24 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbwince.h
  * harbour/source/common/hbwince.c
    + added SetFileAttributesA() for WinCE builds

  * harbour/source/rtl/filesys.c
    * replaced UNICODE translations for SetFileAttributes()
      with direct call to SetFileAttributesA()

  * harbour/include/hbapifs.h
  * harbour/source/rtl/spfiles.c
  * harbour/source/rtl/fstemp.c
  * harbour/source/rtl/hbffind.c
  * harbour/source/rtl/direct.c
  * harbour/source/rtl/filesys.c
    * changed internal representation for file attributes from USHORT
      to ULONG
    + added support for POSIX permission attributes in .c code
    ; added some comments about used attribute translations which
      should be cleand
2008-07-09 16:25:00 +00:00