As on ia64, we need to add the +nodefaultrpath ld option when using the HP 
linker on hppa64.  Without this option,
we end up with the default rpath settings in the embedded search path.  Often, 
this results in path references to build
locations, particularly when libtool doesn't use the +b option to set the 
embedded path.

Better late than never.

Signed-off-by: Dave Anglin <dave.ang...@bell.net>
---

diff --git a/m4/libtool.m4 b/m4/libtool.m4
index f2d1f398..51ad2ae1 100644
--- a/m4/libtool.m4
+++ b/m4/libtool.m4
@@ -5718,7 +5718,7 @@ _LT_EOF
       if test yes,no = "$GCC,$with_gnu_ld"; then
        case $host_cpu in
        hppa*64*)
-         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib 
$libobjs $deplibs $compiler_flags'
+         _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname 
$wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
          ;;
        ia64*)
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname 
$wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
@@ -5730,7 +5730,7 @@ _LT_EOF
       else
        case $host_cpu in
        hppa*64*)
-         _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib 
$libobjs $deplibs $compiler_flags'
+         _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname 
$wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
          ;;
        ia64*)
          _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname 
$wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
@@ -6868,7 +6868,7 @@ if test yes != "$_lt_caught_CXX_error"; then
           aCC*)
            case $host_cpu in
              hppa*64*)
-               _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib 
$predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+               _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname 
$wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects
$compiler_flags'
                ;;
              ia64*)
                _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname 
$wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects
$compiler_flags'
@@ -6892,7 +6892,7 @@ if test yes != "$_lt_caught_CXX_error"; then
              if test no = "$with_gnu_ld"; then
                case $host_cpu in
                  hppa*64*)
-                   _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC 
$wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs
$postdep_objects $compiler_flags'
+                   _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $wl+h 
$wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs
$postdep_objects $compiler_flags'
                    ;;
                  ia64*)
                    _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib 
$pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs
$deplibs $postdep_objects $compiler_flags'

Reply via email to