This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: multiarch proposal


Paul Brook <paul@codesourcery.com> writes:

> On Friday 02 May 2008, Goswin von Brederlow wrote:
>> Paul Brook <paul@codesourcery.com> writes:
>> >> There are two solutions to this problem, both using the gnu tripplet
>> >> to create a unique library location for each architecture:
>> >
>> > Doesn't this assume each multilib has a distinct target triplet? For many
>> > targets this assumption is not valid.  Even on x86_64-linux you could
>> > have multilibs for things like avx.
>> >
>> > Paul
>>
>> It is the most distinct thing I could think of and exists as parameter
>> already. Can you think of anything better?
>
> Not really. However I'll note that gcc already has logic to handle multilibs, 
> so why do we need additional stuff in binutils?
>
> Paul

Not everybody/everything links using gcc.

For reference: gcc on amd64 uses

/usr/bin/ld --eh-frame-hdr -m elf_x86_64 --hash-style=both -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o foo /usr/lib64/crt1.o /usr/lib64/crti.o /usr/lib/gcc/x86_64-linux-gnu/4.2.3/crtbegin.o -L/usr/lib/gcc/x86_64-linux-gnu/4.2.3 -L/usr/lib/gcc/x86_64-linux-gnu/4.2.3 -L/usr/lib64 -L/lib64 -L/usr/lib64 -L/usr/x86_64-linux-gnu/lib -L/usr/lib foo.o -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /usr/lib/gcc/x86_64-linux-gnu/4.2.3/crtend.o /usr/lib64/crtn.o

/usr/bin/ld --eh-frame-hdr -m elf_i386 --hash-style=both -dynamic-linker /lib/ld-linux.so.2 -o foo /usr/lib32/crt1.o /usr/lib32/crti.o /usr/lib/gcc/x86_64-linux-gnu/4.2.3/32/crtbegin.o -L/usr/lib/gcc/x86_64-linux-gnu/4.2.3/32 -L/usr/lib/gcc/x86_64-linux-gnu/4.2.3/32 -L/usr/lib32 -L/lib32 -L/usr/lib32 -L/usr/lib/gcc/x86_64-linux-gnu/4.2.3 -L/usr/lib/gcc/x86_64-linux-gnu/4.2.3 -L/usr/x86_64-linux-gnu/lib -L/usr/lib foo.o -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /usr/lib/gcc/x86_64-linux-gnu/4.2.3/32/crtend.o /usr/lib32/crtn.o

Note that is searching [/usr]/lib32 correctly but
/usr/x86_64-linux-gnu/lib instead of /usr/i486-linux-gnu/lib as it
should be.

So gcc needs some work as well.

MfG
        Goswin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]