Files
harbour-core/harbour/tests/testhrb.prg
Viktor Szakats 501f87d383 2009-06-20 11:36 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* utils/hbmk2/hbmk2.prg
    + Added support for input/output filenames containing spaces.
      Only for msvc and bcc so far.
    ! Fixed to always delete target lib in -hblib + non-incremental mode
      before creating it.
    + Small miracles of life: Microsoft finally added /nologo switch to
      resource compiler in MSVC 2010. Hard to believe, but true. Now
      I'll have to find out what method to use to detect C compiler
      version to enable it.
    + Support for HB_COMPILER_VER envvar to tell hbmk2 what C compiler
      version is expected. Currently only used with MSVC targets.
      Use values like:
        - 710  (for MSVC .NET 2003)
        - 800  (for MSVC 2005)
        - 900  (for MSVC 2008)
        - 1000 (for MSVC 2010)
      The generic format is <99><99>[.<99>] as <major><minor>[.<revision>].
      That makes BCC 5.5.1 '505.1' or shortly '505'.
      Currently the only situation where such switch is necessary is when
      using pre-8.0 MSVC versions, so most users don't have to bother with
      this for now.
      NOTE: Harbour GNU Make compatible HB_VISUALC_VER_PRE80 envvar still
            supported to stay uniform.
    + Added /nologo switch to MSVC lib command.
    ! Protect against adding internally inherited C compiler switches,
      if they are already on the switch list.

  * tests/testhrb.prg
    ! Adapted to latest hbhrb.ch changes.

  * tests/setkeys.prg
    * Minor formatting.
2009-06-20 09:37:56 +00:00

55 lines
1.2 KiB
Plaintext

//
// $Id$
//
// see also exthrb.prg
#include "hbhrb.ch"
Procedure Main(x)
Local pHrb, cExe := "Msg2()", n
n:=iif(x==NIL,0,val(x))
? "calling Msg ... From exe here !"
Msg()
? "========================="
// ? "Loading('exthrb.hrb' )"
// pHrb := hb_HrbLoad("exthrb.hrb" )
// ? "Loading(HB_HRB_BIND_DEFAULT,'exthrb.hrb' )"
// pHrb := hb_HrbLoad(HB_HRB_BIND_DEFAULT,"exthrb.hrb" )
// ? "Loading(HB_HRB_BIND_LOCAL,'exthrb.hrb' )"
// pHrb := hb_HrbLoad(HB_HRB_BIND_LOCAL,"exthrb.hrb" )
? "Loading("+iif(n=0,"HB_HRB_BIND_DEFAULT",iif(n=1,"HB_HRB_BIND_LOCAL","HB_HRB_BIND_OVERLOAD"))+",'exthrb.hrb' )"
pHrb := hb_HrbLoad(n,"exthrb.hrb" )
? "========================="
? "calling Msg ... DEFAULT=From exe, LOCAL=From exe, OVERLOAD=From HRB"
Msg()
? "========================="
? "calling Msg ... DEFAULT=From exe, LOCAL=From HRB, OVERLOAD=From HRB"
&cExe //
? "========================="
hb_HrbUnload( pHrb ) // should do nothing in case of OVERLOAD
? "calling Msg ... DEFAULT=From exe, LOCAL=From exe, OVERLOAD=From HRB"
Msg() // test unload protection when using OVERLOAD ... then .hrb not anymore unloadable
? "========================="
? "END"
Return
Function Msg()
? "Function called from Exe"
Return .T.