libtool-patches
[Top][All Lists]
Advanced

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

Re: x86-64 multilib patch


From: Andreas Jaeger
Subject: Re: x86-64 multilib patch
Date: Fri, 18 Oct 2002 15:05:45 +0200
User-agent: Gnus/5.090008 (Oort Gnus v0.08) XEmacs/21.4 (Artificial Intelligence, i386-suse-linux)

Jakub Jelinek <address@hidden> writes:

> On Fri, Oct 18, 2002 at 10:35:56AM +0200, Andreas Jaeger wrote:
>> 
>> What is the status of this patch?  Following up the discussion on the
>> gcc-patches mailing list about this one, I've added support for some
>> more platforms.  Can somebody commit this, please?
>
>> 2002-10-18  Andreas Jaeger  <address@hidden>,
>>          Bo Thorsen  <address@hidden>
>> 
>>      * libtool.m4: Support linking of 32-bit libraries with ld
>>      on the x86-64, ppc64, s390x and sparc64 GNU/Linux systems.
>
> At least on sparc{,v[789]}-*linux*, s390*-*linux*, ppc*-*linux*
> it should be the other way around too, as you cannot know what's
> the default, ie. something like:
>
> x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
>   # 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
>     *32-bit*)
>       case $host in
>      x86_64-*linux*)
>        LD="${LD-ld} -m elf_i386"
>                ;;
>      ppc*-*linux*|powerpc*-*linux*)
>        LD="${LD-ld} -m elf32ppclinux"
>                ;;
>      s390*-*linux*)
>        LD="${LD-ld} -m elf_s390"
>                ;;
>      sparc*-*linux*)
>        LD="${LD-ld} -m elf32_sparc"
>                ;;
>       esac
>       ;;
>     *64-bit*)
>       case $host in
>      x86_64-*linux*)
>        LD="${LD-ld} -m elf_x86_64"
>                ;;
>      ppc*-*linux*|powerpc*-*linux*)
>        LD="${LD-ld} -m elf64ppc"
>                ;;
>      s390*-*linux*)
>        LD="${LD-ld} -m elf64_s390"
>                ;;
>      sparc*-*linux*)
>        LD="${LD-ld} -m elf64_sparc"
>                ;;
>       esac
>       ;;
>     esac
>   fi
>   rm -rf conftest*
>   ;;
>
> For i?86-*linux* it should probably check for all 3 possibilities, ie.
> *32-bit* -> elf_i386, *64-bit*x86-64* -> elf_x86_64, *64-bit*IA-64* -> 
> elf64_ia64

libtool authors, what solution do you prefer?  Please tell me what to
do so that I can send some patch for this...

> Or of course better fix the linker, so that emulation defaults
> from the first input file.

Or fix libtool to not use ld -r - since this is the only place where
it will case problems...

Andreas
-- 
 Andreas Jaeger
  SuSE Labs address@hidden
   private address@hidden
    http://www.suse.de/~aj




reply via email to

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