Commit Graph

2827 Commits

Author SHA1 Message Date
Przemyslaw Czerpak
39ffeed5f9 2009-01-14 01:38 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/gtxwc/gtxwc.c
    ! added protection against inaccessible character cell value
      what could cause accessing uninitialized memory and GPF

  * harbour/include/hbrdddbf.h
    ! fixed HB_DIRTYREAD() macro not updated when RDDI_* settings were
      converted from global to thread local

  * harbour/source/rdd/dbf1.c
  * harbour/source/rdd/dbfntx/dbfntx1.c
  * harbour/source/rdd/dbfnsx/dbfnsx1.c
  * harbour/source/rdd/dbfcdx/dbfcdx1.c
  * harbour/source/rdd/dbffpt/dbffpt1.c
    % replaced <RDD>NODE_DATA() and <RDD>AREA_DATA() macros defined
      in each RDD by common for all DBF bases RDDs DBFNODE_DATA() and
      DBFAREA_DATA() macros defined in hbrdddbf.h to reduce possible
      mistakes in code updating in the future
2009-01-14 00:35:33 +00:00
Przemyslaw Czerpak
558525e5b5 2009-01-13 22:44 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/bin/hb-func.sh
    ! restored GCC optimization flags in hb* scripts disabled unintentionally
      by some other modifications 

  * harbour/include/hbapifs.h
  * harbour/source/rtl/hbproces.c
    * renamed hb_fsOpenProcess() and hb_fsCloseProcess() to
      hb_fsProcessOpen(), hb_fsProcessClose()

  * harbour/include/hbextern.ch
  * harbour/source/rtl/hbprocfn.c
    * renamed hb_openProcess() and hb_closeProcess() to
      hb_processOpen(), hb_processClose()

  * harbour/contrib/xhb/hbcompat.ch
    * added xHarbour compatible translations
      hb_openProcess() <-> hb_processOpen()
      hb_closeProcess() <-> hb_processClose()
2009-01-13 21:41:13 +00:00
Przemyslaw Czerpak
3b6d1242e5 2009-01-13 14:07 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/common.mak
  * harbour/source/rtl/Makefile
  * harbour/include/hbapifs.h
  * harbour/include/hbextern.ch
  + harbour/source/rtl/hbproces.c
  + harbour/source/rtl/hbprocfn.c
    + added C functions hb_fsOpenProcess(), hb_fsProcessValue(),
      hb_fsCloseProcess()
    + added .prg functions HB_OPENPROCESS(), HB_PROCESSVALUE(),
      HB_CLOSEPROCESS()
    Based on xHarbour code by Giancarlo Niccolai.
    Warning: it's possible that they will be changed in the future.
    Please test current implementation. Now few notes about it.
    Each handle returned by HB_OPENPROCESS() have to be closed
    by HB_PROCESSVALUE(). Even if process is killed by HB_CLOSEPROCESS()
    its handle is still open and HB_PROCESSVALUE() has to be executed.
    Type of handle depends on OS. In *nixes it's process PID. In MS-Windows
    it's HANDLE. HB_PROCESSVALUE() attach process exit result in *nixes
    cleaning zombie processes and in Windows closing the HANDLE. If you
    do not call this function then you will have resource leak.
    HB_CLOSEPROCESS() only sends quite request to the process but does
    not execute any cleanup code.
    All communication handles returned in parameters by reference by
    HB_OPENPROCESS() function have to be closed using FCLOSE() function.
    If hStdOut and hStdErr are references to the same variables then
    executing process stdout and stderr is redirected to the only one
    pipe. When handles for stdout, stderr and stdin are not given then
    executed process inherits them from parent process unless <lDetach>
    parameter is not given. In such case they are redirected to null
    device (/dev/null or NUL).
    The OS2 version is not tested. Please make tests.
    There is no support for DOS which is single process OS.
    In WinCE builds std{out,err,in} redirecting and process detaching does
    not work too.
    The parameters parsing should be updated. Now MS-Windows version uses
    native OS command line parsing and quoting by "" can be used for
    parameters with blank characters. I do not know any escape character
    which can be used to pass (") as parameter to MS-Windows application.
    In all other OS-es standard bourne shell rules are used. Parameters can
    be quoted by "" or '' and escape character is \. Quoting by '' disables
    special meaning of escape character. In OS2 where \ is path separator
    escaping and '' quoting is disabled so it works like in MS-Windows
    but I do not know if parameters divided by calling process are fully
    respected by low level API calls in this system.
2009-01-13 13:04:01 +00:00
Przemyslaw Czerpak
a152f6391f 2009-01-12 23:35 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/cdpapi.c
  * harbour/source/rtl/langapi.c
    * increase maximum number of lang and codepage modules from 64 to 128
      (we already have more then 64)

  * harbour/include/hbgtinfo.ch
    + added HB_GTI_BOXCP - it allows to chose CP for given characters put
      by DISPBOX() and similar box drawing functions.

  * harbour/source/rtl/gttrm/gttrm.c
    + added support for HB_GTI_BOXCP. Now it's possible to change the CP
      used for box drawing characters. Before this modification is was
      hardcoded to "EN"
    * use codepage set by HB_SET{DISP|TERM}CP() also for box characters
      if last parameter <lBox> is true
    This functionality (using different CP for box drawing characters)
    is available only if terminal works in Unicode mode (UTF8).
2009-01-12 22:32:12 +00:00
Maurilio Longo
191fe46098 2009-01-09 12:55 UTC+0100 Maurilio Longo (maurilio.longo@libero.it)
* harbour/config/os2/global.cf
    * simplified and fixed an error in deleting files
  * harbour/source/rtl/hbffind.c
    ! fixed hb_fsFindNextLow() in OS/2 which was using stat to find file size, but
      as it seems, st_size contains garbage. Removed call to stat() and used
      buffer returned by DosFindFirst().
2009-01-09 12:00:57 +00:00
Przemyslaw Czerpak
06c4d78cb4 2009-01-09 01:24 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/hbntos.c
  * harbour/source/rtl/hbrandom.c
    * removed dummy spaces

  * harbour/source/rtl/filesys.c
    * updated HB_TRACE messages

  * harbour/source/rdd/dbfntx/dbfntx1.c
  * harbour/source/rdd/dbfnsx/dbfnsx1.c
    * return pure index name without path and extension for DBOI_BAGNAME just
      like DBFCDX does. It's not Clipper compatible but looks that people
      expects ordBagName() behavior implemented in COMIX CDX driver (CL53).
      Full index name can be accessed by DBOI_FULLPATH.
      If you think it's wrong and we should keep CL52 DBFNTX behavior then
      I can revert it but I will want to also change DBFCDX to keep
      ordBagName() compatible core RDDs.
      Please let me know your preferences.

  * harbour/contrib/hbtpathy/telepath.prg
    ! replaced ThreadSleep() with hb_idleSleep()
2009-01-09 00:21:25 +00:00
Mindaugas Kavaliauskas
ff670e6c36 2009-01-08 13:12 UTC+0200 Mindaugas Kavaliauskas (dbtopas/at/dbtopas.lt)
* harbour/source/compiler/hbopt.c
    * improved 'variable assigned but unused' detection logic
  * harbour/source/rtl/treport.prg
    * fixed assigned but unused variable
2009-01-08 11:16:23 +00:00
Przemyslaw Czerpak
c2a1acc14c 2009-01-05 13:33 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbgtcore.h
  * harbour/source/rtl/hbgtcore.c
    * changed BYTE bClearColor to USHORT uiClearColor


  The following modifications were made by Viktor Szakats,
  (2008-11-22 16:15 UTC+0100 - 2008-12-19 12:56 UTC+0100)
  Many thanks. It's the first part without CP conversions in OS calls which
  I will want to check yet. Please tests MS-Windows only modifications.

  * harbour/make_vc.mak
  * harbour/contrib/mtpl_vc.mak
    + Added support for A_USR.

  * harbour/include/set.ch
  * harbour/include/hbextern.ch
  * harbour/source/vm/cmdarg.c
  * harbour/source/vm/set.c
  * harbour/source/rtl/tgetlist.prg
  * harbour/source/rtl/gete.c
  * harbour/contrib/hbhpdf/harupdf.c
    * formatting

  * harbour/source/rtl/hbffind.c
    * Changed few places to use sizeof() instead of
      explicit size macro.

  * harbour/source/vm/extrap.c
    + Added module listing. (also supports Win64)

  * harbour/source/common/hbver.c
    + Added Intel C compiler detection. (from xhb)
    + Added Wine detection (unofficial but stable looking
      detection method. There intentionally doesn't exist
      an official method to do this detection, yet there
      are cases when this is necessary. It's also essential
      for error reports.)
      See also:
      http://www.mail-archive.com/wine-devel@winehq.org/msg48659.html

  * harbour/source/common/hbfopen.c
    ! Reverted recent change to use fopen_s(). fopen_s()
      will always open in exclusive mode, so it could create
      incompatibilities.

  * harbour/source/codepage/cpbgmik.c
    ! Fixed BGMIK collation encoding. Someone familiar with
      BG CPs please confirm this, but previously it was
      almost certainly broken, as the collation was identical
      to BG866.

  * harbour/source/rtl/diskspac.c
  * harbour/source/rtl/disksphb.c
    ! GetModuleHandleA() -> GetModuleHandle()
    ; NOTE: GetModuleHandleA() WinCE emulation in
            source/common/wince.c might be unnecessary
            after this change.

  * harbour/source/rtl/memoedit.prg
  * harbour/source/rtl/teditor.prg
    ! Cleaned insert handling. It now won't anymore mess up
      the cursor on instantiation (in New() method). Internal
      :lInsert state replaced by Set( _SET_INSERT ). Cursor
      is only touched in the editing loop.

  * harbour/source/rtl/version.c
    ! HB_VERSION( HB_VERSION_BUILD_DATE ): Fixed month
      being off by one.

  * harbour/contrib/hbmzip/hbmzip.c
    ! Fixed typo which caused timestamps stored in .zip files
      to be wrong.

  * harbour/contrib/hbhpdf/tests/harupdf.prg
    ! Minor typo in code.

  * harbour/contrib/rddads/rddads.h
    + Added detection for ACE 9.10.

  * harbour/contrib/hbtip/sendmail.prg
    ! Stricter parameter checking in hb_SendMail().

  * harbour/contrib/examples/dbu/hb_dbu.dif
    + Added SET DATE ANSI and SET CENTURY ON

  * harbour/source/rtl/gtxwc/gtxwc.c
    + Generating HB_K_RESIZE keystrokes on screen resize.
      This way it's working similarly to gtwvt.
    ! Typos in comments.

  * harbour/source/rtl/gtwin/gtwin.c
    ! Fixed HB_GTI_KBDSHIFTS not working in console mode.
      Replaced GetKeyboardState() call with GetKeyState() calls.

  * harbour/source/rtl/gtwvt/gtwvt.c
    + Added 'layered' window support. It's enabled on W2K
      and above (and only when not in Terminal Services
      environment, because it makes it perform worse). This
      way the screen is also properly displayed regardless
      of what the Harbour application does. It also fixes
      numerous paint artifacts, when GTWVT window was in
      the background and another window is moved in front
      of it.
    ! Fixed only generate HB_K_RESIZE keystrokes when
      resize mode is HB_GTI_RESIZEMODE_ROWS.
2009-01-05 12:31:02 +00:00
Mindaugas Kavaliauskas
d2856c340f 2008-12-25 11:14 UTC+0200 Mindaugas Kavaliauskas (dbtopas/at/dbtopas.lt)
* include/hbextern.ch
  * source/rtl/seconds.c
    + implemented hb_milliseconds(). This function returns time value 
      from some moment in the past (not midnigth!). It does not start 
      to cound from zero in midnight, thus, can be safetly used to 
      measure time intervals.
  + tests/ticktime.c
    + Added nice test for hb_milliseconds().
      Results on WinXP:
        Ticks per second: 63.595
        Min/avg/max interval (ms): 15.000 / 15.724 / 47.000
        Loops per tick:      13035.09
      Results on openSUSE on VirtualBox on WinXP:
        Ticks per second: 384306.138
        Min/avg/max interval (ms): 0.001 / 0.003 / 11.112
        Loops per tick:      1.04
2008-12-25 09:12:32 +00:00
Mindaugas Kavaliauskas
e3b721a3ba 2008-12-24 03:23 UTC+0200 Mindaugas Kavaliauskas (dbtopas/at/dbtopas.lt)
* include/hberrors.h
  * source/compiler/hbgenerr.c
  * source/compiler/hbopt.c
    + implemented warning: Variable '%s' is never assigned in function %s(%d).
      This variable can be replaced by value NIL

  * source/rtl/treport.prg
    % removed never assigned variable
2008-12-24 01:22:16 +00:00
Przemyslaw Czerpak
b16bf45375 2008-12-22 16:30 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/ChangeLog
    ! cleaned some typos in my recent ChangeLog entries

  * harbour/include/hbvm.h
  * harbour/include/hbvmpub.h
  * harbour/include/hbsetup.h
  * harbour/include/hbapi.h
  * harbour/include/hbapierr.h
    * added some function attributes which can improve code optimization
      or introduce some additional warnings.
      Now it works only in GCC builds.

  * harbour/source/vm/hvm.c
    ! fixed missing double decimal places initialization in some number
      negating
    ! fixed setting number of decimal places in plus and minus operations
      if integer overflow forces conversion to double item
    * some minor optimizations

  * harbour/source/rtl/rat.c
    * formatting
2008-12-22 15:28:29 +00:00
Przemyslaw Czerpak
6b668123d6 2008-12-19 19:46 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/filesys.c
    * do not respect _SET_PATH when hb_{file|fs}ExtOpen() is called
      with create file attributes - Clipper compatibility.

  * harbour/source/vm/set.c
    * recognize files starting with "/dev/" as devices in *nixes
    * check if given file name is a name of existing device (character,
      block, fifo, socket) in *nix builds
    * ignore _SET_DEFAULT and default extension in _SET_PRINTFILE,
      _SET_ALTFILE and _SET_EXTRAFILE when given file name is device name.
      In DOS/Windows/OS2 builds devices are recognized by name:
      "PRN", "CON", "LPT[1-3]", "COM[1-9]"
2008-12-19 18:44:35 +00:00
Przemyslaw Czerpak
4c56ab22f8 2008-12-19 04:30 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/contrib/hbmysql/tmysql.prg
  * harbour/contrib/hbpgsql/pgrdd.prg
  * harbour/contrib/hbpgsql/tpostgre.prg
    ! fixed unused variables and meaningless assignment detected by new
      compiler extension - many thanks to Mindaugas for it.

  * harbour/include/hbsetup.h
    + added macros for some function attributes which can be used in
      the future for optimizations

  * harbour/source/rtl/filesys.c
    * formatting

  * harbour/source/rtl/hbtoken.c
    * changed the behavior of " " token delimiter - now it works as
      any other tokens. The old behavior can be still reach using empty
      string "" as token delimiter. "" is not default token.

  * harbour/utils/hbtest/hbtest.prg
    * change error object to text conversion in hbtest so now it detects also
      differences which were ignored by previous version, f.e. OPERATION
      wrongly used instead of FILENAME or wrongly set TRIES flag.

  * harbour/utils/hbtest/hbtest.prg
  * harbour/utils/hbtest/rt_trans.prg
  * harbour/utils/hbtest/rt_math.prg
  * harbour/utils/hbtest/rt_hvm.prg
  * harbour/utils/hbtest/rt_misc.prg
  * harbour/utils/hbtest/rt_hvma.prg
  * harbour/utils/hbtest/rt_class.prg
  * harbour/utils/hbtest/rt_str.prg
  * harbour/utils/hbtest/rt_stra.prg
  * harbour/utils/hbtest/rt_date.prg
  * harbour/utils/hbtest/rt_array.prg
    * updated for extended error messages, tested with Harbour, Cl52/53

  * harbour/include/hbapierr.h
  * harbour/source/rtl/errorapi.c
    + added hb_errRT_FileError() used in file errors
    ! fixed TRIES counter updating when RETRY flag is set - it should
      be done before calling error block not after - detected by new
      hbtest error messages
    ; TOFIX: in practice all errors with RETRY flag generated by
             other hb_errRT_*() functions have to be fixed because
             new error object is created each time and informations
             from previous one are lost, f.e. TRIES counter or CARGO
             value set by user. They should be reimplemented in similar
             way to hb_errRT_FileError()

  * harbour/source/vm/memvars.c
  * harbour/source/rtl/copyfile.c
  * harbour/source/vm/set.c
    ! fixed wrong error messages detected by new hbtest in _SET_PRINTFILE,
      _SET_ALTFILE and _SET_EXTRAFILE
    ; TOCHECK - Does CA-Cl*pper respect _SET_DEFAULT in above SETs?
2008-12-19 03:28:10 +00:00
Mindaugas Kavaliauskas
dde57c5c70 2008-12-18 05:02 UTC+0200 Mindaugas Kavaliauskas (dbtopas/at/dbtopas.lt)
* include/hbclass.ch
  * include/hbcomp.ch
  * include/hberrors.h
  * include/hbgenerr.c
  * include/hbmain.c
  * include/hbopt.c
    + PCode optimizations:
        1) Self := QSELF(), Self:method -> QSELF():method
        2) Declared, but unused variables are removed from code
      These optimizations are enabled if jump optimizations are enabled.

    + added recursive pcode tree tracer. It is capable to generate new
      warning: Variable %s is assigned, but not used. 
      Warning is not generated in these cases:
        1) unoptimal Self := QSELF() pcode [generated by preprocessor rules]
        2) if variable name starts with '_nowarn_'. This allows to 
           suppress warning in case unoptimal pcode is generated by 
           preprocessor rules
        3) assigned value is NIL. This let us force garbage collection
           using oVar := NIL
      Warning has warning level 3.
      ; NOTE: if you are using -w3 -es2 in makefiles, you'll need to fix your 
              redundant code to compile the project

  * source/rtl/achoice.prg
  * source/rtl/browse.prg
  * source/rtl/tbrowse.prg
  * source/rtl/teditor.prg
  * source/rtl/tget.prg
  * source/rtl/tgetlist.prg
  * source/rtl/tlabel.prg
  * source/rtl/tmenusys.prg
  * source/rtl/tpersist.prg
  * source/rtl/treport.prg
  * source/debug/dbgtmenu.prg
  * source/debug/debugger.prg
  * source/debug/dbgtobj.prg
    * fixed 'assigned but not used' warnings

  * utils/hbdoc/hbdoc.prg
  * utils/hbdoc/genasc.prg
  * utils/hbdoc/genhpc.prg
  * utils/hbdoc/genhtm.prg
  * utils/hbdoc/genchm.prg
  * utils/hbdoc/genng.prg
  * utils/hbdoc/genos2.prg
  * utils/hbdoc/genrtf.prg
  * utils/hbdoc/gentrf.prg
  * utils/hbdoc/ft_funcs.prg
  * utils/hbmake/hbmake.prg
    * #pragma -w2
    ; NOTE: I've been fixing warnings in utils/hbdoc/* for 2 hours, 
      but only fixed half of files. There are a lot of garbage code here.
      I do not thing this code is working... 
      I used fallback method: restored original files and used -w2
    ; NOTE: hbmake.prg has about 140 unused assignments.
      I've also fallback to -w2, because some of unused code is complex, 
      ex., ASCAN() with block parameters. I'm not using hbmake, and I'm 
      affraid to break something important. 

  * compiler/hbpcode.c
    - removed Ron's copyright on hb_compStrongType(). We do not have this 
      functions in the compiler at all. I guess this text is just a result 
      of .c header copy-paste from xHarbour's hbstrong.c some time ago.
2008-12-18 03:04:50 +00:00
Przemyslaw Czerpak
fa31aa6f70 2008-12-11 19:48 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbthread.h
  * harbour/source/vm/thread.c
    + added hb_atomic_set(), hb_atomic_get(), hb_atomic_inc() and
      hb_atomic_dec() functions which operates on HB_COUNTER or smaller
      type if it's necessary for some platforms which can be access/assign
      increment/decrement in MT safe atom operations.
      hb_atomic_dec() returns true if counter is 0 after decrementation

  * harbour/include/hbatomic.h
    ! fixed compilation in Linux and OpenWatcom

  * harbour/include/hbapiitm.h
  * harbour/source/rtl/itemseri.c
    + make hb_itemSerialize() and hb_itemDeserialize() public functions
    ! fixed serialization items with internal item references

  * harbour/source/vm/hvm.c
    * release memvars after closing RDDs

  * harbour/source/debug/dbgentry.c
    ! fixed buffer overflow reported by Rodrigo

  * harbour/source/vm/macro.c
  * harbour/source/compiler/hbmain.c
    * formatting

  * harbour/include/hbexprb.c
    ! fixed wrongly recognized functions with HB_I18N_ prefix as
      HB_I18N_GETTEXT()

  * harbour/include/hbapi.h
  * harbour/include/hbstack.h
  * harbour/include/hbthread.h
  * harbour/source/vm/estack.c
  * harbour/source/vm/thread.c
  * harbour/source/vm/hvm.c
    + added support for I18N in HVM.
      Each thread can have it's own i18n set.
      When new thread is created then it inherits i18n set from parent
      thread and both uses the same set (please remember about it if you
      will want to make some direct modifications on active i18n set
      internals).
      When thread change active i18n set then it effects only this thread
      and new threads which will be create later. It does not change i18n
      in other existing threads.
    + added functions to set/get pointer to active i18n set in HVM
         void * hb_vmI18N( void )
         void   hb_vmSetI18N( void * )

  * harbour/include/hbapi.h
  * harbour/source/rtl/hbi18n.c
    + added i18n module. Now only for internal Harbour usage without support
      for optional switching to alternative implementations.
      I'll add such functionality later when I will work on native gettext
      support.

      The following public .prg functions has been added:
         HB_I18N_GETTEXT[_STRICT]( <cMsgID> [, <cContext> ] )
               -> <cTranslatedMsgID> | <cMsgID>
         HB_I18N_NGETTEXT[_STRICT]( <nValue>, <cMsgID> | <acMsgID> ;
                                    [, <cContext> ] )
               -> <cTranslatedMsgID> | <cMsgID> | <acMsgID>[ <nIndex> ]
      This is minimal support necessary for .prg code which has to exists
      in each i18n module working with Harbour.

      The following functions had been added as public C API:
         PHB_ITEM hb_i18n_gettext( PHB_ITEM pMsgID, PHB_ITEM pContext )
         PHB_ITEM hb_i18n_ngettext( PHB_ITEM pNum,
                                    PHB_ITEM pMsgID, PHB_ITEM pContext )

      The following functions had been added as private HVM C API:
         void   hb_i18n_init( void )
         void   hb_i18n_exit( void )
         void   hb_i18n_release( void * cargo )
         void * hb_i18n_alloc( void * cargo )
      They have to be supported by alternative i18n modules

      The following functions has been added to manage Harbour i18n
      translations sets:

         HB_I18N_CREATE()
                  -> <pI18N>
            Creates new empty I18N translation set

         HB_I18N_CODEPAGE( [<pI18N>,] [<cNewCP>], [<lBase>], [<lTranslate>] )
                  -> <cOldCP>
            Gets or sets Harbour codepage used by translation set
            <pI18N> - I18N translation set,
                      if it's not given then currently active I18N set is used
            <cNewCP> - new CP ID. Must be linked with application
            <lBase> - when it's .T. then get/set base massages CP instead of
                      translated massages CP
            <lTranslate> - if it's .T. then translate base (<lBase>==.T.) or
                           final messages in I18N set from previous CP to
                           given one. Base messages translation in synced
                           with context ID translation.

         HB_I18N_PLURALFORM( [<pI18N>,] [<cNewForm>|<bNewForm>], [<lBase>] )
                  -> <cOldForm>|<bOldForm>
            Gets or sets plural form used for final or base messages
            <pI18N> - I18N translation set,
                      if it's not given then currently active I18N set is used
            <cNewForm> - language ID of plural form, f.e.: "EN", "PL", "LT".
                         Now only three above are supported. Please add rules
                         for other languages to source/rtl/hbi18n.c.
            <bNewForm> - codeblock used to calculate plural form indexes.
                         can be used instead of character representation but
                         it's not storred in serialized I18N set
            <lBase> - when it's .T. then get/set base massages plural form
                      instead of translated massages one.

         HB_I18N_DESCRIPTION( [<pI18N>,] [<cNewDescription>] )
                  -> <cOldDescription>
            Gets or sets translation set description. After serialization
            up to 32 bytes is stored in header which can be easy used to
            determinate type of translation file.
            <pI18N> - I18N translation set,
                      if it's not given then currently active I18N set is used
            <cNewDescription> - new description

         HB_I18N_ADDTEXT( <pI18N>, <cMsgID>, <cTrans> | <acTrans> [, <cContext> ] )
                  -> NIL
            Adds new message with translation to i18n translation set
            <pI18N> - I18N translation set
            <cMsgID> - original message
            <cTrans> - translated message
            <acTrans> - array with translated messages used for plural forms
            <cContext> - message context

         HB_I18N_SET( [ <pI18N> | NIL ] )
                  -> <lActive>
            Sets given I18N translation set as default one used by
            HB_I18N_[N]GETTEXT[_STRICT]() functions or remove translation
            set for calling thread when passed parameter is NIL
            <pI18N> - I18N translation set
            Returns logical value which is .T. when i18n set is active

         HB_I18N_SAVETABLE( [<pI18N>] )
                  -> <cTable>
            Returns I18N translation as string item which can be stored
            in file or database
            <pI18N> - I18N translation set, if it's not given then currently
                      active I18N set is used

         HB_I18N_RESTORETABLE( <cTable> )
                  -> <pI18N> | NIL
            Restores I18N translation set from strin item.
            <cTable> - I18N translation set in string representation
            On success it returns new <pI18N> set otherwise NIL if <cTable>
            is not valid item created by HB_I18N_SAVETABLE() or it's corrupted.

         HB_I18N_HEADERSIZE()
                  -> <nHeaderSize>
            Returns size of header used by i18n serialized version

         HB_I18N_CHEK( <cTable> | <cHeader> [, @<cDescription> ] )
                  -> <lValid>
            <cTable> - i18n translation set serialized by HB_I18N_SAVETABLE
            <cHeader> - header of i18n translation set
                        ( LEFT( <cTable>, HB_I18N_HEADERSIZE() )
            <cDescription> - optional parameter passed by reference where
                             will be sored i18n translation set description
                             extracted from valid header
            Returns logical value indicating if given table or header is
            valid serialized by HB_I18N_SAVETABLE() data. It does not
            decode the table though it validates size and control sums.

      These functions are optional and some future alternative implementations
      may not support all of them and/or may provide some other functions.

    + added unofficial .prg function __I18N_HASHTABLE() which allows to
      access hash table used by i18n translation set or create new translation
      set with given hash table. It's helper functions for developers which
      will work on Harbour i18n tools and should not be used by Harbour users.

      Unlike original gettext Harbour allows to use language with many
      plural forms as base one. In such case programmer should activate
      at application startup default i18n translation set with base plural
      form valid for base application language, f.e. by:
         pI18N := hb_i18n_create()
         hb_i18n_pluralForm( pI18N, <cLangID> | <bForm>, .t. )
         hb_i18n_set( pI18N )
      .prg code example:

         #xtranslate _( <x,...> ) => hb_i18n_gettext_strict( <x> )
         #xtranslate _N( <x,...> ) => hb_i18n_ngettext_strict( <x> )

         proc main()
            local pI18N, i

            pI18N := hb_i18n_create()
            hb_i18n_pluralForm( pI18N, "PL", .t. )
            hb_i18n_set( pI18N )

            for i := 0 to 30
               ? i, _N( i, {"grosz", "grosze", "groszy"} )
               if i > 0 .and. i % 10 == 0
                  wait
               endif
            next
         return

      In .pot files created during compilation by Harbour with -j option
      for above code we have the following entries for message with plural
      forms:
            msgid "grosz"
            msgid_plural "grosze"
            msgid_plural2 "groszy"
            msgstr[0] ""
      The msgid_plural2 (and others if language has more plural forms)
      is Harbour extension which is not gettext compatible.


      The above implementation is base version but should be fully functional.
      Now we will need functions to safe/read i18n files and tools to mange
      .pot files: merge them, edit translations, create final binary i18n
      translation sets. Because we are using gettext compatible .pot files
      then for some of such jobs we can use original gettext tools but we
      need at least function which will create translation set from one or
      more .pot files.
      We should also agree some default localization(s) for files containing
      translated data, their name convention and environment variable(s)
      to set default language. It's not strictly necessary and each user
      can have his own implementation but it would help in adding new
      translations by final users to any Harbour application which will
      respect them. We can use LANG envvar to extract preferred language
      and use the same path as executed application looking for files
      <appname>-<lang>.hil files though it may create some problems for
      OSes which support only 8.3 file names so we can also define that
      HB_I18N envvar has higher priority and points to expected translation
      file.

  * harbour/include/hbextern.ch
    - removed old __i18n_*() functions
    + added current i18n functions
2008-12-11 18:47:46 +00:00
Miguel Angel Marchuet Frutos
ec3c2b40ac 2008-12-04 10:11:55 +00:00
Przemyslaw Czerpak
5721fcf996 2008-12-03 18:35 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/common/hbstr.c
    ! added missing call to va_end() in hb_snprintf()

  * harbour/source/vm/classes.c
    + added internal helper function __objSetClass()

  * harbour/source/rtl/valtoexp.prg
    * set class in expressions serialized by hb_valToExp()

  * harbour/source/rtl/valtostr.c
    % optimized hb_strToExp()

  * harbour/contrib/xhb/hbcompat.ch
    ! removed unnecessary conversion for HB_ISPOINTER() in xHarbour part.
2008-12-03 17:34:28 +00:00
Przemyslaw Czerpak
7ad0d5f23f 2008-11-26 18:22 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/vm/itemapi.c
    * changed hb_itemPutNLen() function to create integer item only
      when conversion to HB_LONG does not change value of passed double
      argument. It fixes some problems like restoring non integer double
      values with 0 decimal places by __MVRESTORE()

  * harbour/source/rtl/val.c
    % minor optimization
2008-11-26 17:21:08 +00:00
Przemyslaw Czerpak
f3a3469af0 2008-11-24 16:41 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/pp/ppcore.c
  * harbour/source/rtl/run.c
  * harbour/source/rtl/errorint.c
  * harbour/source/rtl/trace.c
  * harbour/contrib/xhb/hboutdbg.c
    * pacified warnings and updated some possibly danger constructions

  * harbour/source/vm/memvars.c
    % improved the performance of __MVRESTORE()
    ; TOFIX: this code has Clipper incompatible extension which may cause
      that incorrect values will be restored - numeric double values with
      0 as default number of decimal places for str() formatting are
      wrongly converted to integers loosing fractional part of number.
2008-11-24 15:40:18 +00:00
Przemyslaw Czerpak
2e6b5eee7d 2008-11-24 12:34 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hberrors.h
  * harbour/source/compiler/hbgenerr.c
    + added new compile time error (file write error)

  * harbour/source/pp/ppcore.c
  * harbour/source/rtl/errorint.c
  * harbour/source/compiler/genhrb.c
  * harbour/source/compiler/genc.c
  * harbour/source/rtl/run.c
  * harbour/source/vm/estack.c
    * pacified warnings - Lorenzo please verify it compiling with C header
      files from Ubuntu.

  * harbour/contrib/xhb/filestat.c
    ! fixed UNICODE compilation

  * harbour/contrib/gtwvg/wvgsink.c
    ! added #define NONAMELESSUNION to fix MinGW compilation
2008-11-24 11:33:13 +00:00
Viktor Szakats
f5a6a8112f 2008-11-18 02:53 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/gtwvt/gtwvt.c
    ! Fix to previous fix to maximize the window when the initial 
      size would be too big to fit on screen (stupid omission).
      Now the previously cited sizing problem is alright.

  * source/vm/fm.c
    + Replaced HB_NO_FM_STAT and HB_FM_STAT envvars 
      with HB_FM_STAT=yes|no (maybe 0|1 or on|off woud be 
      better or could be accepted as alternatives or 
      replacement). This is to avoid ambiguity when both 
      envvars were set or the app default is not known.
    + Added HB_FM_STATISTICS_DYN_OFF to turn off mem tracking 
      by default when stat module is linked in.

  * source/common/hbverdsp.c
    * Minor cosmetic.
2008-11-18 01:59:51 +00:00
Przemyslaw Czerpak
26534784e8 2008-11-12 23:28 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/hbgtcore.c
    ! removed code I committed by mistake.
2008-11-12 22:27:19 +00:00
Przemyslaw Czerpak
3e2a8a9fc6 2008-11-12 23:16 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/vm/fm.c
    + added support for enabling/disabling memory statistic when
      application starts. To enable memory statistic it's enough
      to set HB_FM_STAT environment variable to non empty value.
      To disable memory statistic it's enough to set HB_NO_FM_STAT
      envvar. The default setting may depend on build time option.
      Now is enabled when memory statistic is compiled when harbour
      is created. It may not work if C compiler does not allow to
      check environment variables from startup code. F.e. functions
      to access environment can be also part of dynamic library
      registered after harbour.dll or harbour core code startup
      functions.
      Viktor I would like to ask you only about one thing.
      Please do not remove current support for HB_FM_STATISTICS_OFF
      from GNU make builds so Harbour user can still create binaries
      without any memory statistic code using -[no]fmstat switch in
      hb* scripts. The above feature is only for users who need support
      for enabling/disabling memory statistic to test application
      if foreign environment, f.e. at client computers. Of course if
      it will work with given C compiler and/or type of application
      (linked dynamically or statically). Please check.
2008-11-12 22:15:28 +00:00
Viktor Szakats
ffae8f9489 2008-11-11 12:08 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/console.c
    ! Fixed __EJECT() writing an EJECT only if output device 
      was "PRINTER". This fixes problem reported by Ciro, and 
      also a very old TOFIX which was removed very long ago 
      by mistake. (see thread "Bug: __EJECT() (David)" on 2000-07-27)
      [TOMERGE 1.0]

  * source/rtl/treport.prg
    ! Fixed some linefeed differences.
      [TOMERGE 1.0]

  * source/vm/set.c
    * Minor formatting.
2008-11-11 11:09:30 +00:00
Viktor Szakats
9a28707aba 2008-11-11 02:35 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* make_b32.mak
  * make_vc.mak
  * make_gcc.mak
    + Added -DHB_TR_LEVEL_DEBUG C compiler option when 
      HB_BUILD_DEBUG=yes.

  * source/rtl/hbinet.c
    * Minor formatting.
2008-11-11 01:36:18 +00:00
Viktor Szakats
8f6aa8e802 2008-11-11 00:39 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* make_b32.mak
  * make_vc.mak
    ! Fixed linking hbtest-dll.exe with tracing enabled.

  * bin/hbmk.bat
    + Added '-shared' option.
    ; TOFIX: - '-shared' won't work in binary installations.
             - '-shared' cannot create MT apps.
             - '-shared' only works for BCC32 yet.

  - tests/hbmk_b32_dll.bat
    - Removed. Use 'hbmk_b32 -shared' instead.

  * source/rtl/treport.prg
    * Minor formatting.

  * make_b32.bat
  * make_vc.bat
  * common.mak
    * Changed default of HB_BUILD_DLL to 'yes'.
2008-11-10 23:44:17 +00:00
Przemyslaw Czerpak
ae5075fa5b 2008-11-10 00:20 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/config/rules.cf
    ! fixed recursive HB_FLAGS declaration

  * harbour/include/hbdefs.h
  * harbour/include/hbsetup.h
  * harbour/include/hbtrace.h
    * declared hb_tr_trace() parameters as printf() compatible in GCC
      builds. It enabled format string with parameters validation

  * harbour/source/rtl/errorapi.c
    ! fixed GPF caused by HB_ERR_FUNCNAME which is not longer valid
      string

  * harbour/source/vm/itemapi.c
  * harbour/source/vm/hvm.c
  * harbour/source/vm/arrays.c
  * harbour/source/vm/memvars.c
  * harbour/source/vm/eval.c
  * harbour/source/vm/extend.c
  * harbour/source/vm/set.c
  * harbour/source/debug/dbgentry.c
  * harbour/source/rtl/gtwin/gtwin.c
  * harbour/source/rtl/gtxwc/gtxwc.c
  * harbour/source/rtl/hbgtcore.c
  * harbour/source/rtl/gtcrs/gtcrs.c
  * harbour/source/rtl/gtstd/gtstd.c
  * harbour/source/rtl/gtsln/gtsln.c
  * harbour/source/rtl/gttrm/gttrm.c
  * harbour/source/rtl/gtpca/gtpca.c
  * harbour/source/rtl/gtcgi/gtcgi.c
  * harbour/source/rtl/gtwvt/gtwvt.c
  * harbour/source/rtl/filesys.c
  * harbour/source/rdd/dbf1.c
  * harbour/source/rdd/dbffpt/dbffpt1.c
  * harbour/contrib/gtalleg/gtalleg.c
  * harbour/contrib/xhb/freadlin.c
  * harbour/contrib/gtwvg/gtwvg.c
  * harbour/contrib/rddads/adsfunc.c
  * harbour/contrib/rddads/ads1.c
  * harbour/contrib/hbwin/win_ole.c
  * harbour/utils/hbdoc/hbdfrdln.c
  * harbour/utils/hbmake/hbmfrdln.c
    ! fixed bugs in HB_TRACE massages reported in GCC builds
2008-11-09 23:20:16 +00:00
Viktor Szakats
69952de84f 2008-11-09 20:58 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* include/hbdefs.h
  * include/hbapigt.h
  * source/common/hbfsapi.c
  * source/rtl/console.c
  * source/rtl/fserror.c
  * source/rtl/fstemp.c
  * source/rtl/gtstd/gtstd.c
  * source/rtl/gtpca/gtpca.c
  * source/rtl/filesys.c
    * Macro rename:
      - HB_WIN32_IO_OFF -> HB_IO_WIN_OFF
      - HB_WIN32_IO     -> HB_IO_WIN
    ; NOTE: INCOMPATIBLE if someone happens to disable 
            Windows native IO. Users don't normally 
            needs this though.
2008-11-09 19:59:39 +00:00
Viktor Szakats
618407cbec 2008-11-09 17:03 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* contrib/gtwvg/wvgcore.c
  * contrib/gtwvg/wvgutils.c
  * contrib/hbwin/win_dll.c
  * contrib/hbwin/win_ole.c
  * contrib/xhb/cstructc.c
  * contrib/xhb/dbgfxc.c
  * source/common/hbarch.c
  * source/common/hbdate.c
  * source/common/hbfsapi.c
  * source/common/hbstr.c
  * source/common/hbver.c
  * source/common/hbverdsp.c
  * source/debug/dbgentry.c
  * source/main/harbour.c
  * source/rdd/dbf1.c
  * source/rdd/nulsys/nulsys.c
  * source/rdd/wacore.c
  * source/rdd/wafunc.c
  * source/rdd/workarea.c
  * source/rtl/cdpapi.c
  * source/rtl/console.c
  * source/rtl/dates.c
  * source/rtl/errorint.c
  * source/rtl/file.c
  * source/rtl/filesys.c
  * source/rtl/fscopy.c
  * source/rtl/fserror.c
  * source/rtl/fstemp.c
  * source/rtl/gtapi.c
  * source/rtl/gtapiu.c
  * source/rtl/hbadler.c
  * source/rtl/hbcrc.c
  * source/rtl/hbffind.c
  * source/rtl/hbgtcore.c
  * source/rtl/hbmd5.c
  * source/rtl/inkeyapi.c
  * source/rtl/isprint.c
  * source/rtl/math.c
  * source/rtl/mouseapi.c
  * source/rtl/seconds.c
  * source/rtl/setcolor.c
  * source/rtl/setcurs.c
  * source/rtl/strmatch.c
  * source/vm/hvm.c
    % Removed HB_EXPORT from function definitions.
      Placing it in declaration is enough.

  * source/debug/dbgentry.c
    * Formatting.
2008-11-09 16:06:36 +00:00
Viktor Szakats
0b765b9181 2008-11-09 16:00 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* make_b32.mak
  * make_vc.mak
    ! Added hbpp.lib and hbcommon.lib to HBRUN_DLL liblist.

  * include/hbapi.h
  * source/vm/cmdarg.c
  * source/common/hbver.c
  * source/common/hbverdsp.c
  * source/rtl/console.c
  * source/rtl/setcolor.c
  * source/rtl/setcurs.c
    + Added HB_EXPORT to some functions to make it possible 
      to build hbrun-dll.exe.
      For other reasons, it only works if Harbour built with 
      set C_USR=-DHB_DYNLIB.
    ; TODO: Make HB_DYNLIB the default build mode, do gradual 
            steps to remove separate DLL building pass, and 
            finally to remove HB_BUILD_DLL option.
            The only drawback will be about 10-100K 
            (currently) overhead in final executable size due 
            to included export table for BCC and MSVC builds.
2008-11-09 15:04:03 +00:00
Viktor Szakats
10457b0fcf 2008-11-09 15:46 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* contrib/xhb/hboutdbg.c
    ! Fixed to compile without warnings and with more 
      consistent behavior across platforms.

  * source/rtl/gtwvt/gtwvt.c
    * Minor formatting.
2008-11-09 14:47:44 +00:00
Viktor Szakats
8b095d9c56 2008-11-09 14:23 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* tests/longstr.prg
  * contrib/hbole/oleauto.prg
  * contrib/hbole/ole2.c
  * contrib/gtwvg/wvgutils.c
  * contrib/gtwvg/wvgcore.c
  * contrib/hbgd/gdbarcod.prg
  * contrib/hbgd/gdbar.prg
  * contrib/hbwin/win_tole.prg
  * contrib/hbwin/win_ole.c
  * contrib/hbvpdf/hbvpdf.prg
  * contrib/examples/hbsqlit2/tests/hbsqlite.prg
  * contrib/examples/hbsqlit2/TODO.txt
  * contrib/examples/hbsqlit2/hbsqlit2.c
  * source/debug/dbgwa.prg
  * source/rtl/gtwin/gtwin.c
  * source/rtl/tget.prg
  * source/rtl/tgetint.prg
  * source/compiler/gencobj.c
    ! Removed high chars from comments. This usually means 
      copyright holders' names. I apologize for touching 
      them, I also have one in mine, but it's better to 
      not use them in source code to avoid encoding problems.
2008-11-09 13:25:55 +00:00
Viktor Szakats
642efdc827 2008-11-09 14:02 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* make_vc.mak
    + Added /nxcompat linker flag for non-WinCE, non-DLL, 
      HB_VISUALC_VER >= 80 MSVC executables. 
      This should add extra safety.

  * include/hbextern.ch
  * source/rtl/rat.c
    + Added HB_RAT() which is similar to RAT(), but also accepts 
      <nStart> and <nEnd> optional paramaters, similarly to HB_AT().
    ; Please test.

  * source/rtl/at.c
    * Minor formatting.
2008-11-09 13:03:31 +00:00
Przemyslaw Czerpak
c497f05e91 2008-11-09 13:16 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/vm/memvars.c
    ! fixed 3 tracelog messages

  * harbour/source/rtl/hbgtcore.c
    * declare core method table as const

  * harbour/source/compiler/gencc.c
    ! fixed accessing data out of buffer in string to hex conversion and
      logical expression used to divide strings
2008-11-09 12:15:27 +00:00
Viktor Szakats
5b53f67db4 2008-11-09 11:48 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* ChangeLog
    ! Restored last non-UNICODE version, and readded
      all entries and reapplied all changes since then.
    ; NOTE: Please never save any Harbour files in
            UNICODE mode. Thank you.

  * contrib/make_gcc_all.sh
  * contrib/Makefile
    - Removed hbdbgfx.

  * source/pp/hbpp.c
  * source/main/harbour.c
    * Excluded hbwmain for __POCC__ WinCE.
    ; TOFIX: Warning: Not proper fix.
             This way it won't link but at least it compiles.

  * source/compiler/gencc.c
    * Switched to hexadecimal format for high chars, because
      octal was tried to be converted to Windows codepage, by
      PellesC.

  * config/w32/poccce.cf
    - Removed -DSTRSAFE_NO_DEPRECATE switch.

  * config/w32/pocc.cf
    + Added -MT switch.

  * contrib/hbwin/win_prn2.c
  * contrib/hbwin/win_dll.c
  * source/rtl/hbhex.c
  * source/rdd/hbsix/sxcompat.prg
    * Minor formatting.
2008-11-09 11:15:06 +00:00
Pritpal Bedi
51f934239f 2008-11-08 15:40 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
* harbour/contrib/gtwvg/gtwvg.c
  * harbour/contrib/gtwvg/gtwvg.h
  * harbour/source/rtl/gtwvt/gtwvt.c
  * harbour/source/rtl/gtwvt/gtwvt.h
    
    + BOOL bResizing
    + BOOL bAlreadySizing
      To control unnecessary code execution while sizing operation is 
      being carried out. Now the flickering of console window should be
      greatly minimized, IMO, please test.

    ! Fixed behavior of some function not to recreate font if one is already
      created given other parameters are the same. SetMode() does nothing if
      nRows, nCols are the same as with console prior to calling this function.
     
    ; NOTE: Please test extensively as this is one gray area of GTWVT we all
      are in a quest to fix.
2008-11-08 23:47:17 +00:00
Viktor Szakats
0a3c1096aa 2008-11-08 16:43 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/version.c
    % Minor.
2008-11-08 15:43:26 +00:00
Viktor Szakats
50e1dd9efc 2008-11-08 16:18 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/version.c
    + Implemented:
      hb_version( HB_VERSION_BUILD_DATE )
      hb_version( HB_VERSION_BUILD_TIME )

  * source/rtl/gtwvt/gtwvt.c
    * Formatting.

  * source/rdd/hbsix/sxini.prg
  * source/rdd/hbsix/sxcompat.prg
  * source/rdd/hbsix/sxtrig.prg
    * Formatted to std Harbour. Generated pcode unchanged.

  * ChangeLog
    * Marked finished TODO/TOFIXes as [DONE].
2008-11-08 15:20:16 +00:00
Viktor Szakats
0167128c05 2008-11-08 12:46 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/gtwvt/gtwvt.c
    * hb_gt_wvt_ResetWindowSize(): Not very good looking (or 
      overly efficient) solution added for the windows 
      resize/positioning problem in case the initally set size 
      cannot fit on the screen (Windows desktop).
2008-11-08 11:47:52 +00:00
Viktor Szakats
d58f588682 2008-11-08 10:25 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/vm/set.c
    + Implemented rest of hb_setSetItem() values.
    ; TODO: Please review.
    ! Fixed HB_SET_FILECASE and HB_SET_DIRCASE to not allow 
      invalid numeric values to be set.
    ! Added missing 'break;' to hb_setSetItem2();

  * source/rtl/gtwvt/gtwvt.c
    ! Fixed a few places where '+' operator was used 
      instead of '|'.
    * Minor opt/formatting.
    ; TOFIX: The window positioning bug is still to be solved.
2008-11-08 09:40:27 +00:00
Viktor Szakats
e8f4681b90 2008-11-07 19:02 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/gtwvt/gtwvt.c
    * Formatting.

  * config/w32/owatcom.cf
    * Added support for L_USR in link options.
    * Removed debug switch -d2 from compiler command line.
      For debug builds 'C_USR=-d2' and 'L_USR=debug all' 
      should be added.

  ; Untested.
2008-11-07 18:03:35 +00:00
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
5afcd6feae 2008-11-05 19:26 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* contrib/hbcurl/hbcurl.c
    % Removed two Harbour level functions not really 
      adding to functionality but forcing linkage of these 
      (otherwise unused) curl interfaces.
      CURL_SHARE_STRERROR()
      CURL_MULTI_STRERROR()
      INCOMPATIBLE (but I doubt even a single user would be affected)

  * source/rtl/version.c
    ! Fix to prev.
2008-11-05 18:28:27 +00:00
Viktor Szakats
efa79fba05 2008-11-05 13:15 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* make_vc.mak
    * -GA option only used for HB_VISUALC_VER >= 70.
      Please update this if older versions also support it.

  * include/hbver.ch
  * source/common/hbver.c
    * Some more fiddling with version number terminology and 
      hb_version() values:
      HB_VERSION_MICRO          -> HB_VERSION_RELEASE
      HB_VERSION_BLD_DATE_STR   -> HB_VERSION_BUILD_DATE_STR
      HB_VERSION_BLD_DATE       -> HB_VERSION_BUILD_DATE
      HB_VERSION_BLD_TIME       -> HB_VERSION_BUILD_TIME
      HB_VERSION_CHANGELOG_REV  -> HB_VERSION_CHANGELOG_ID
      Third part of version number could also be: PATCH, MICRO, BUILD
      SVN revision could also be: BUILD
      BUILD is inherently connected with a physical binary, so 
      I dropped it, PATCH is limiting and negativ, MICRO is not 
      very common (otherwise good), so a finally opted for 
      RELEASE. REVISION kept as is.
    ; If there are no objections I'll HB_VER_REVISION macro to 
      HB_VER_RELEASE. This will be an INCOMPATIBLE change, but 
      I expect not too many ppl being affected.

  * TODO
    - Removed MT as a TODO. Thanks Przemek for the nice job.
2008-11-05 12:16:30 +00:00
Przemyslaw Czerpak
bb49e3711a 2008-11-04 22:39 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbapi.h
  * harbour/source/vm/hashfunc.c
  * harbour/source/vm/hashes.c
    + added support for binary key order
    % enable binary internal key order by default for new hash arrays
    + added .prg function to enable/disable/retrive binary order in hash
      items:
         hb_hSetBinary( <hValue>, <lOnOff> ) => <hValue>
         hb_hBinary( <hValue> [, <lBinary> ] ) => <lBinary>
    + added support for hash array resorting. It's activated automatically
      on 1-st key access/assign after changing binary or casematch hash
      array flag
    + added .prg function hb_hSort( <hValue> ) => <hValue> which marks
      hash array for sorting

  * harbour/source/rtl/itemseri.c
    % improved performance of hash array deserialization
      TODO: add support for hash array flags and hash default value
            serialization
2008-11-04 21:39:10 +00:00
Przemyslaw Czerpak
e2ef86bf9b 2008-11-04 09:40 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbgtcore.h
    ! added missing 'extern' in hb_gt_dos_keyCodeTranslate() declaration

  * harbour/source/rtl/gtstd/gtstd.c
  * harbour/source/rtl/gtpca/gtpca.c
    + added support for console input in OpenWatcom builds

  * harbour/source/vm/vmmt/Makefile
    ! removed mainpm.c

  * harbour/contrib/xhb/hbcrypt.c
    ! fixed casting
2008-11-04 08:39:45 +00:00
Przemyslaw Czerpak
80eb21edc9 2008-11-04 02:12 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/seconds.c
    + added #include <process.h> to OpenWatcom OS2 builds.
2008-11-04 01:11:25 +00:00
Przemyslaw Czerpak
de26bf0591 2008-11-04 02:08 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/vm/thread.c
    * removed casting to void* thread startup function passed
      as _beginthread() parameter in OS2 builds. It should be checked if
      it does not breaks GCC builds.

  * harbour/source/rtl/seconds.c
    * use getpid() instead of _getpid() in non GCC OS2 builds
2008-11-04 01:07:55 +00:00
Przemyslaw Czerpak
0142b12622 2008-11-04 01:04 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbthread.h
    ! fixed typo

  * harbour/source/vm/Makefile
    * excluded mainpm.c from OS2 builds

  * harbour/source/rtl/hbinet.c
    * changed the #include order for OS2 OpenWatcom builds and added some
      cleanups - please test other builds.
2008-11-04 00:03:46 +00:00