2008-08-25 20:36 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* utils/hbmake/hbmake.prg
! Harbour executable detection cleanups and fix to look
into current dir and detect Darwin as a Unix platform.
(usable state is still very far)
This commit is contained in:
@@ -8,6 +8,12 @@
|
||||
2008-12-31 13:59 UTC+0100 Foo Bar (foo.bar foobar.org)
|
||||
*/
|
||||
|
||||
2008-08-25 20:36 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
|
||||
* utils/hbmake/hbmake.prg
|
||||
! Harbour executable detection cleanups and fix to look
|
||||
into current dir and detect Darwin as a Unix platform.
|
||||
(usable state is still very far)
|
||||
|
||||
2008-08-25 20:14 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
|
||||
* harbour/contrib/hbw32/w32_ole.c
|
||||
* removed hack with malloc()/free() directly used to avoid
|
||||
|
||||
@@ -6790,38 +6790,33 @@ RETURN aDir
|
||||
FUNCTION GetHarbourDir()
|
||||
*-----------------------
|
||||
|
||||
LOCAL cPath := ""
|
||||
LOCAL cEnv := GETE( "PATH" )
|
||||
LOCAL lLinux := "LINUX" $ upper(OS())
|
||||
LOCAL lUnix := iif( "UNIX" $ upper(OS()) .OR. "HP-UX" $ upper(OS()), .T., .F. )
|
||||
LOCAL aEnv
|
||||
LOCAL cCurEnv := ""
|
||||
LOCAL cBar := iif( lLinux .or. lUnix, "/" , "\" )
|
||||
LOCAL HBSTRG := ""
|
||||
LOCAL cPathUni:= GETE( "PATH_HARBOUR" )
|
||||
LOCAL lUnix := "LINUX" $ Upper( OS() ) .OR. ;
|
||||
"UNIX" $ Upper( OS() ) .OR. ;
|
||||
"HP-UX" $ Upper( OS() ) .OR. ;
|
||||
"DARWIN" $ Upper( OS() )
|
||||
|
||||
hbstrg := IIF ( lLinux .or. lUnix, "harbour" , "harbour.exe" )
|
||||
LOCAL cBar := iif( lUnix, "/" , "\" )
|
||||
LOCAL HBSTRG := iif( lUnix, "harbour", "harbour.exe" )
|
||||
LOCAL cPathUni := GetEnv( "PATH_HARBOUR" )
|
||||
LOCAL aEnv := hb_ATokens( GetEnv( "PATH" ), iif( lUnix, ":", ";" ) )
|
||||
LOCAL cCurEnv
|
||||
|
||||
If lUnix
|
||||
If cPathUni == Nil
|
||||
cPathUni := ""
|
||||
EndIF
|
||||
cEnv += ":" + cPathUni
|
||||
EndIf
|
||||
AAdd( aEnv, "." + cBar )
|
||||
|
||||
aEnv := HB_ATokens( cEnv, iif(lLinux .or. lUnix,":",";") )
|
||||
IF !Empty( cPathUni )
|
||||
AAdd( aEnv, cPathUni )
|
||||
ENDIF
|
||||
|
||||
FOR EACH cCurEnv IN aEnv
|
||||
FOR EACH cCurEnv IN aEnv
|
||||
|
||||
IF FILE( cCurEnv + cBar + hbstrg ) .OR. FILE( UPPER( cCurEnv ) + cBar + upper(hbstrg) )
|
||||
cPath := cCurEnv
|
||||
cPath := LEFT( cPath, RAT( cBar, cPath ) - 1 )
|
||||
EXIT
|
||||
ENDIF
|
||||
IF File( cCurEnv + cBar + hbstrg ) .OR. ;
|
||||
File( Upper( cCurEnv + cBar + hbstrg ) )
|
||||
|
||||
NEXT
|
||||
RETURN Left( cCurEnv, RAt( cBar, cCurEnv ) - 1 )
|
||||
ENDIF
|
||||
NEXT
|
||||
|
||||
RETURN cPath
|
||||
RETURN ""
|
||||
|
||||
*-------------------
|
||||
FUNCTION GetBccDir()
|
||||
|
||||
Reference in New Issue
Block a user