libtool-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Fix libtool on HP-UX/IA-64


From: Albert Chin
Subject: Fix libtool on HP-UX/IA-64
Date: Fri, 4 Nov 2005 11:15:49 -0600
User-agent: Mutt/1.5.6i

The following patch fixes libtool-1.5 on HP-UX 11.23/IA-64.
  1. If you specify +b and -L, -L doesn't embed the path into
     DT_RPATH. Hence, removal of hardcode_minus_L=yes.
  2. If you specify only -L's without +nodefaultrpath, they are
     embedded into DT_RPATH.
  3. It's just easier to rely on +b throughout, like hppa*64.

There is one problem. If a library is created _without_ +b (because it
has no dependencies) but -L in LDFLAGS, the paths from -L will get
hardcoded into the library. Uck! The fix is to add
${wl}+nodefaultrpath. Should we do this for _every_ library we create
on ia64*? I say yes. I'll deal with that issue and some others in a
separate patch.

-- 
albert chin (address@hidden)

-- snip snip
2005-11-04  Albert Chin-A-Young  <address@hidden>

        * libtool.m4 (AC_LIBTOOL_LANG_CXX_CONFIG,
        AC_LIBTOOL_PROG_LD_SHLIBS): hardcode_libdir_flag_spec
        and hardcode_minus_L are the same for hppa*64 and
        ia64*. Don't set hardcode_libdir_flag_spec='-L$libdir'
        on ia64* because if you specify +b and -L, +b overrides
        what is set into DT_RPATH.

Index: libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/Attic/libtool.m4,v
retrieving revision 1.314.2.120
diff -u -3 -p -r1.314.2.120 libtool.m4
--- libtool.m4  1 Nov 2005 16:24:58 -0000       1.314.2.120
+++ libtool.m4  4 Nov 2005 16:46:03 -0000
@@ -3143,34 +3143,23 @@ case $host_os in
     ;;
   hpux10*|hpux11*)
     if test $with_gnu_ld = no; then
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
       case $host_cpu in
-      hppa*64*)
-       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+      hppa*64*|ia64*)
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-       _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
-        ;;
-      ia64*)
-       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
         ;;
       *)
-       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-       _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
        _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
         ;;
       esac
     fi
     case $host_cpu in
-    hppa*64*)
+    hppa*64*|ia64*)
       _LT_AC_TAGVAR(hardcode_direct, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
       ;;
-    ia64*)
-      _LT_AC_TAGVAR(hardcode_direct, $1)=no
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
-                                             # but as the default
-                                             # location of the library.
-      ;;
     *)
       _LT_AC_TAGVAR(hardcode_direct, $1)=yes
       _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
@@ -5828,26 +5817,16 @@ EOF
        esac
       fi
       if test "$with_gnu_ld" = no; then
+       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+       _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
        case $host_cpu in
-       hppa*64*)
-         _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+       hppa*64*|ia64*)
          _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-         _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
-         _LT_AC_TAGVAR(hardcode_direct, $1)=no
-         _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-         ;;
-       ia64*)
-         _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
          _LT_AC_TAGVAR(hardcode_direct, $1)=no
          _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-
-         # hardcode_minus_L: Not really in the search PATH,
-         # but as the default location of the library.
-         _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
          ;;
        *)
-         _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-         _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
          _LT_AC_TAGVAR(hardcode_direct, $1)=yes
          _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]