libtool-patches
[Top][All Lists]
Advanced

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

FYI: Solaris, combining a bunch of convenience archives


From: Ralf Wildenhues
Subject: FYI: Solaris, combining a bunch of convenience archives
Date: Tue, 1 Nov 2005 17:25:01 +0100
User-agent: Mutt/1.5.9i

* Ralf Wildenhues wrote on Fri, Oct 14, 2005 at 04:52:30PM CEST:
> * Ralf Wildenhues wrote on Thu, Oct 13, 2005 at 09:19:06AM CEST:
> > * Albert Chin wrote on Wed, Oct 12, 2005 at 11:21:50PM CEST:
> > > 
> > > If libtool sees -xarch=v9, it should add -64 to the linker
> > > command-line.
> > 
> > Yes, certainly.  This solves the issue for branch-1-5, where we use
> > `$LD' to link.  (Of course, we could backport using $CC for linking
> > instead, but mind the following.)
> 
> Here's a (pretty minimal) fix for branch-1-5.  OK?

Applied to branch-1-5 as shown, and CVS HEAD as below, for consistency.

Cheers,
Ralf

        * libltdl/m4/libtool.m4 (_LT_ENABLE_LOCK) [ solaris ]: Add `-64'
        to $LD if necessary, to permit combining of several convenience
        libs without any further objects added.
        Reported by Brian Barrett <address@hidden>.

Index: libltdl/m4/libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/libltdl/m4/libtool.m4,v
retrieving revision 1.31
diff -u -r1.31 libtool.m4
--- libltdl/m4/libtool.m4       1 Nov 2005 16:08:48 -0000       1.31
+++ libltdl/m4/libtool.m4       1 Nov 2005 16:23:15 -0000
@@ -1167,6 +1167,21 @@
     CFLAGS="$SAVE_CFLAGS"
   fi
   ;;
+sparc*-*solaris*)
+  # Find out which ABI we are using.
+  echo 'int i;' > conftest.$ac_ext
+  if AC_TRY_EVAL(ac_compile); then
+    case `/usr/bin/file conftest.o` in
+    *64-bit*)
+      case $lt_cv_prog_gnu_ld in
+      yes*) LD="${LD-ld} -m elf64_sparc" ;;
+      *)    LD="${LD-ld} -64" ;;
+      esac
+      ;;
+    esac
+  fi
+  rm -rf conftest*
+  ;;
 esac
 
 need_locks="$enable_libtool_lock"




reply via email to

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