2010-08-06 18:55 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)

* debian/rules
    + Added LD_LIBRARY_PATH.
      (it's needed here because the called make process won't
      pass back any envvars to caller process)

  * config/global.mk
    + Shows LD_LIBRARY_PATH in log.
    - Do not clear HB_SYSLOC to allow override (from package makers).
    + Export HB_DYNLIB_PREF (for postinst.hbs).

  * config/postinst.hbs
    + Creating Harbour dynamic lib symlinks, like the old postinst.sh
      did. This fixes Debian build problems, and probably more.
    ; TODO: I didn't implement one scenario, I'd appreciate if someone
            with bash and *nix skill could decipher the old code
            and create the few .prg lines for this functionality.
    ! Fixed .hbx creation for core dynlibs on *nix systems.
This commit is contained in:
Viktor Szakats
2010-08-06 16:56:40 +00:00
parent a44c9ab3a7
commit e5fd8dcb36
4 changed files with 83 additions and 32 deletions

View File

@@ -16,6 +16,25 @@
The license applies to all entries newer than 2009-04-28.
*/
2010-08-06 18:55 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* debian/rules
+ Added LD_LIBRARY_PATH.
(it's needed here because the called make process won't
pass back any envvars to caller process)
* config/global.mk
+ Shows LD_LIBRARY_PATH in log.
- Do not clear HB_SYSLOC to allow override (from package makers).
+ Export HB_DYNLIB_PREF (for postinst.hbs).
* config/postinst.hbs
+ Creating Harbour dynamic lib symlinks, like the old postinst.sh
did. This fixes Debian build problems, and probably more.
; TODO: I didn't implement one scenario, I'd appreciate if someone
with bash and *nix skill could decipher the old code
and create the few .prg lines for this functionality.
! Fixed .hbx creation for core dynlibs on *nix systems.
2010-08-06 09:32 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)
* contrib/hbide/resources/blockindentl.png
* contrib/hbide/resources/blockindentr.png
@@ -46,7 +65,7 @@
* contrib/hbide/idedocks.prg
* contrib/hbide/ideedit.prg
+ Rationalized: icon colors, now they present a professional look.
% Fixed: behavior of few MDI area toolbars actions,
% Fixed: behavior of few MDI area toolbars actions,
went weired after the introduction of MDI concept.
2010-08-06 15:50 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)

View File

@@ -1148,6 +1148,9 @@ else
export LD_LIBRARY_PATH := $(realpath $(DYN_DIR)):$(LD_LIBRARY_PATH)
endif
export HB_LD_PATH_SET := yes
ifneq ($(LD_LIBRARY_PATH),)
$(info ! LD_LIBRARY_PATH: $(LD_LIBRARY_PATH))
endif
endif
endif
DYN_PREF :=
@@ -1449,8 +1452,6 @@ export HB_VERSION
export HB_PKGNAME
export HB_PKGNAMI
HB_SYSLOC :=
HB_INSTALL_PREFIX_ORI := $(HB_INSTALL_PREFIX)
ifeq ($(HB_BUILD_PKG),yes)
ifeq ($(HB_INIT_DONE),)
@@ -1807,5 +1808,6 @@ include $(TOP)$(ROOT)config/globsh.mk
export HB_DYNLIB_EXT := $(DYN_EXT)
export HB_DYNLIB_DIR := $(DYN_DIR)
export HB_DYNLIB_PREF := $(DYN_PREF)
endif # GLOBAL_MK_

View File

@@ -50,6 +50,11 @@ PROCEDURE Main( ... )
LOCAL cSH_Script
LOCAL nAttr
LOCAL cST_Versioned
LOCAL cST_Versionless
LOCAL cMT_Versioned
LOCAL cMT_Versionless
IF Empty( GetEnv( "HB_PLATFORM" ) ) .OR. ;
Empty( GetEnv( "HB_COMPILER" ) ) .OR. ;
Empty( GetEnv( "HB_HOST_BIN_DIR" ) )
@@ -143,37 +148,41 @@ PROCEDURE Main( ... )
ENDIF
ENDIF
/* TOFIX: Rewrite this in .prg */
#if 0
FOR EACH tmp IN { GetEnv( "HB_DYNLIB_ST" ), GetEnv( "HB_DYNLIB_MT" ) }
IF ! Empty( GetEnv( "HB_INSTALL_DYN" ) )
OutStd( "! Creating dynamic lib symlinks..." + hb_eol() )
OutStd( GetEnv( "HB_INSTALL_DYN" + hb_ps() + tmp + hb_eol() )
cST_Versioned := GetEnv( "HB_DYNLIB_PREF" ) + GetEnv( "HB_DYNLIB_ST" ) + GetEnv( "HB_DYNLIB_EXT" )
cST_Versionless := GetEnv( "HB_DYNLIB_PREF" ) + GetEnv( "HB_DYNLIB_BASE_ST" ) + GetEnv( "HB_DYNLIB_EXT" )
cMT_Versioned := GetEnv( "HB_DYNLIB_PREF" ) + GetEnv( "HB_DYNLIB_MT" ) + GetEnv( "HB_DYNLIB_EXT" )
cMT_Versionless := GetEnv( "HB_DYNLIB_PREF" ) + GetEnv( "HB_DYNLIB_BASE_MT" ) + GetEnv( "HB_DYNLIB_EXT" )
ll="` echo $l | sed 's!'${lib_suff}'$!!' `${lib_ext}"
ln -sf $l $ll
mk_hb_FLinkSym( cST_Versioned, PathSepToSelf( GetEnv( "HB_INSTALL_DYN" ) ) + hb_ps() + cST_Versionless )
mk_hb_FLinkSym( cMT_Versioned, PathSepToSelf( GetEnv( "HB_INSTALL_DYN" ) ) + hb_ps() + cMT_Versionless )
IF !( GetEnv( "HB_PLATFORM" ) $ "win|wce" )
DO CASE
CASE GetEnv( "HB_INSTALL_DYN" ) $ "/usr/lib/harbour|/usr/lib64/harbour|/usr/local/lib/harbour|/usr/local/lib64/harbour"
ln -sf harbour/$l ../$ll
ln -sf harbour/$l ../$l
;;
CASE GetEnv( "HB_INSTALL_DYN" ) $ "/usr/local/harbour/lib"
ld="/usr/lib"
if [ -n "${HB_INST_PKGPREF}" ] || [ -w $ld ]
then
mkdir -p ${HB_INST_PKGPREF}$ld
ln -sf ../local/harbour/lib/$l ${HB_INST_PKGPREF}$ld/$ll
ln -sf ../local/harbour/lib/$l ${HB_INST_PKGPREF}$ld/$l
fi
;;
*)
;;
ENDCASE
ENDIF
fi
done
#endif
DO CASE
CASE EndsWith( GetEnv( "HB_INSTALL_DYN" ), "/usr/lib/harbour" ) .OR. ;
EndsWith( GetEnv( "HB_INSTALL_DYN" ), "/usr/lib64/harbour" ) .OR. ;
EndsWith( GetEnv( "HB_INSTALL_DYN" ), "/usr/local/lib/harbour" ) .OR. ;
EndsWith( GetEnv( "HB_INSTALL_DYN" ), "/usr/local/lib64/harbour" )
mk_hb_FLinkSym( "harbour" + hb_ps() + cST_Versioned, PathSepToSelf( GetEnv( "HB_INSTALL_DYN" ) ) + hb_ps() + ".." + hb_ps() + cST_Versionless )
mk_hb_FLinkSym( "harbour" + hb_ps() + cST_Versioned, PathSepToSelf( GetEnv( "HB_INSTALL_DYN" ) ) + hb_ps() + ".." + hb_ps() + cST_Versioned )
mk_hb_FLinkSym( "harbour" + hb_ps() + cMT_Versioned, PathSepToSelf( GetEnv( "HB_INSTALL_DYN" ) ) + hb_ps() + ".." + hb_ps() + cMT_Versionless )
mk_hb_FLinkSym( "harbour" + hb_ps() + cMT_Versioned, PathSepToSelf( GetEnv( "HB_INSTALL_DYN" ) ) + hb_ps() + ".." + hb_ps() + cMT_Versioned )
CASE GetEnv( "HB_INSTALL_DYN" ) == "/usr/local/harbour/lib"
/* TOFIX: Rewrite this in .prg */
#if 0
ld="/usr/lib"
if [ -n "${HB_INST_PKGPREF}" ] || [ -w $ld ]
then
mkdir -p ${HB_INST_PKGPREF}$ld
ln -sf ../local/harbour/lib/$l ${HB_INST_PKGPREF}$ld/$ll
ln -sf ../local/harbour/lib/$l ${HB_INST_PKGPREF}$ld/$l
fi
#endif
ENDCASE
ENDIF
/* Creating language files */
@@ -509,6 +518,20 @@ STATIC PROCEDURE mk_hb_FCopy( cSrc, cDst, l644 )
RETURN
/* Like hb_FLinkSym(), but with feedback */
STATIC PROCEDURE mk_hb_FLinkSym( cDst, cSrc )
IF hb_FLinkSym( cDst, cSrc ) == 0
OutStd( hb_StrFormat( "! Symlink: %1$s <= %2$s", cDst, cSrc ) + hb_eol() )
ELSE
OutStd( hb_StrFormat( "! Error: Creating symlink %1$s <= %2$s", cDst, cSrc ) + hb_eol() )
ENDIF
RETURN
STATIC FUNCTION EndsWith( cString, cEnd )
RETURN Right( cString, Len( cEnd ) ) == cEnd
STATIC FUNCTION query_stdout( cName )
LOCAL cStdOut
LOCAL cStdErr
@@ -551,7 +574,7 @@ STATIC FUNCTION mk_extern_core()
! Empty( GetEnv( "HB_DYNLIB_ST" ) )
/* TOFIX: Use list of libs instead of dynamic lib */
IF ( aExtern := __hb_extern_get_list( PathSepToSelf( GetEnv( "HB_DYNLIB_DIR" ) ) + hb_ps() + GetEnv( "HB_DYNLIB_ST" ) + GetEnv( "HB_DYNLIB_EXT" ) ) ) != NIL
IF ( aExtern := __hb_extern_get_list( PathSepToSelf( GetEnv( "HB_DYNLIB_DIR" ) ) + hb_ps() + GetEnv( "HB_DYNLIB_PREF" ) + GetEnv( "HB_DYNLIB_ST" ) + GetEnv( "HB_DYNLIB_EXT" ) ) ) != NIL
OutStd( "! Generating core extern headers..." + hb_eol() )

View File

@@ -15,6 +15,13 @@ export HB_INSTALL_DOC := $(HB_INSTALL_PKG_ROOT)/usr/share/doc/harbour
export HB_INSTALL_MAN := $(HB_INSTALL_PKG_ROOT)/usr/share/man
export HB_INSTALL_ETC := $(HB_INSTALL_PKG_ROOT)/etc/harbour
ifeq ($(LD_LIBRARY_PATH),)
export LD_LIBRARY_PATH := $(HB_INSTALL_DYN)
else
export LD_LIBRARY_PATH := $(LD_LIBRARY_PATH):$(HB_INSTALL_DYN)
endif
export HB_SYSLOC := yes
export HB_BUILD_PKG := no
export HB_BUILD_SHARED := yes
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))