home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / harbb30g.zip / DOC / hrb_faq.txt < prev    next >
Text File  |  1999-06-21  |  2KB  |  71 lines

  1. .HRB FAQ list 1999/05/19:
  2.  
  3. Current only available in a 32bit Intel version.
  4.  
  5. HRB structure (also known as Harbour Portable Objects) and
  6. Runner (also known as TugBoat, Stubbing Executables (not yet) )
  7.  
  8. To create a runner :
  9.  
  10.         c:..> bld32exe runner
  11.  
  12. Once the runner is created,
  13. To create a .HRB and run it :
  14.  
  15.         c:..> hbrun <filename>
  16.  
  17.  
  18. If you just want to run a .HRB file :
  19.  
  20.         c:..> runner <filename with .HRB>
  21.  
  22. If you just want to create a .HRB file :
  23.  
  24.         Use command-line switch -gHRB when invoking Harbour
  25.  
  26. To see the contents of a .HRB file :
  27.  
  28.         c:...> clipper readhrb /n/a/w           {I am sorry}
  29.         c:...> blinker @readhrb
  30.         c:...> readhrb <filename without .HRB>  {What do mean consistent}
  31.  
  32.         If it goes too fast a readhrb.out is created containing the screen
  33.         output.
  34.  
  35. To run a .HRB file within a .PRG (only possible if the .PRG is compiled as a
  36. .HRB file) :
  37.  
  38.         HB_Run( <cFileName> )
  39.  
  40. -------------------------------------------------------------------------------
  41. HRB structure (also known as Harbour Portable Objects) and
  42. Runner (also known as TugBoat, Stubbing Executables (not yet) )
  43.  
  44. Version 1.0
  45.  
  46. The ultimate version will of course feature more, but let's just stick to the
  47. minimal requirements.
  48.  
  49. The .HRB structure consists :
  50.  
  51. <ulSymbols>       Long containing the number of symbols
  52. {
  53.     <szSymbol>    Name of symbol
  54.     <bScope>      Scope of symbol
  55.     <bLinkType>   Link type :
  56.                   0 = NO_LINK (ie DATA symbol)
  57.                   1 = FUNCTION* in .PRG itself
  58.                   2 = EXTERN. Link function pointer at run-time.
  59. }
  60. <ulFuncs>         Long containing the number of functions
  61. {
  62.     <szSymbol>    Name of function
  63.     <ulLen>       Length of function
  64.     <aPCode>      PCode of function
  65. }
  66.  
  67. * Since the module name itself is a symbol during compilation. ProcName()
  68.   was recognized as an internal function.
  69.   During the run-time link the runner therefore checks whether the compiler
  70.   has correctly identified a symbol as contained in .PRG itself.
  71.