Okay, this way it's perfect, because the PCODE version hack is missing.

Brgds,
Viktor

On 2008.07.02., at 12:40, Miguel Angel Marchuet wrote:

MORE OR LESS rdd uses the same system to add INIT functions

HB_INIT_SYMBOLS_BEGIN( dbfcdx1__InitSymbols )
{ "DBFCDX", {HB_FS_PUBLIC|HB_FS_LOCAL}, {HB_FUNCNAME( DBFCDX )}, NULL }, { "DBFCDX_GETFUNCTABLE", {HB_FS_PUBLIC|HB_FS_LOCAL}, {HB_FUNCNAME( DBFCDX_GETFUNCTABLE )}, NULL }
HB_INIT_SYMBOLS_END( dbfcdx1__InitSymbols )

HB_CALL_ON_STARTUP_BEGIN( _hb_dbfcdx_rdd_init_ )
  hb_vmAtInit( hb_dbfcdxRddInit, NULL );
HB_CALL_ON_STARTUP_END( _hb_dbfcdx_rdd_init_ )

#if defined(HB_PRAGMA_STARTUP)
#  pragma startup dbfcdx1__InitSymbols
#  pragma startup _hb_dbfcdx_rdd_init_
#elif defined(HB_MSC_STARTUP)
#  if _MSC_VER >= 1010
#     pragma data_seg( ".CRT$XIY" )
#     pragma comment( linker, "/Merge:.CRT=.data" )
#  else
#     pragma data_seg( "XIY" )
#  endif
static HB_$INITSYM hb_vm_auto_dbfcdx1__InitSymbols = dbfcdx1__InitSymbols; static HB_$INITSYM hb_vm_auto_dbfcdx_rdd_init = _hb_dbfcdx_rdd_init_;
#  pragma data_seg()
#endif

Best regards,
Miguel Angel Marchuet


Szakáts Viktor escribió:
It looks a bit hackish, but if there is no other way to
solve this, I think you should commit it.
Brgds,
Viktor
On 2008.07.02., at 12:21, Miguel Angel Marchuet wrote:
I prefer to add it and forgot to call manually to this function.


Can I add it ?


#define __PRG_SOURCE__ (char*) "zip.c"
#ifdef HB_PCODE_VER
#  undef HB_PRG_PCODE_VER
#  define HB_PRG_PCODE_VER HB_PCODE_VER
#endif

HB_INIT_SYMBOLS_BEGIN( hbzip_CLEANUP )
{ (char*) "HBZIPCLEANUP$", {HB_FS_EXIT | HB_FS_LOCAL}, {HB_EXIT_FUNCNAME( HBZIPCLEANUP )}, &ModuleFakeDyn }
HB_INIT_SYMBOLS_END( hbzip_CLEANUP )

#if defined(HB_PRAGMA_STARTUP)
#pragma startup hbzip_CLEANUP
#elif defined(HB_MSC_STARTUP)
#if _MSC_VER >= 1010
   #pragma data_seg( ".CRT$XIY" )
   #pragma comment( linker, "/Merge:.CRT=.data" )
#else
   #pragma data_seg( "XIY" )
#endif
static HB_$INITSYM hb_vm_auto_SymbolInit_INIT = hbzip_CLEANUP;
#pragma data_seg()
#endif



Best regards,
Miguel Angel Marchuet
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to