[PATCH 0 of 2] Static toolchain support

Bryan Hundven bryanhundven@gmail.com
Sun Dec 5 09:22:00 GMT 2010


Yann, All,
On Tue, Nov 2, 2010 at 10:30 AM, Bryan Hundven <bryanhundven@gmail.com> wrote:
> On Mon, Nov 1, 2010 at 2:51 PM, Bryan Hundven <bryanhundven@gmail.com> wrote:
>> On Mon, Oct 18, 2010 at 6:49 PM, Arnaud Lacombe <lacombar@gmail.com> wrote:
>>> Hi,
>>>
>>> On Mon, Oct 18, 2010 at 5:12 PM, Bryan Hundven <bryanhundven@gmail.com> wrote:
>>>> These commits add support for statically linked toolchains.
>>>> You must turn on CT_EXPERIMENTAL to use this toolchain, as there
>>>> is still one problem left to solve.
>>>>
>>>> The toolchain that is produced builds static and dynamic binaries
>>>> with the (GNU/Linux) elf header rather then the expected (SYSV) elf header.
>>>>
>>>> I have found two articles on the topic where one says it is a problem with
>>>> binutils, and the other says it is a problem with (e)glibc.
>>>>
>>>> Any suggestions on fixing this?
>>>>
>>> Not yet, but having articles' URLs might be helpful.
>>>
>>>  - Arnaud
>>>
>>
>> When building ct-ng with (e)glibc >= 2.11 and building either a
>> statically linked toolchain or the normal dynamically linked
>> toolchain, I still notice that the elf OSABI is "(GNU/Linux) - 3" and
>> not "(SYSV) - 0"
>>
>> bryan@flubber:~/x-tools/i686-nptl-linux-gnu$ find . | xargs file |
>> grep '(GNU/Linux)'
>> ./i686-nptl-linux-gnu/sys-root/sbin/sln:
>>                   ELF 32-bit LSB executable, Intel 80386, version 1
>> (GNU/Linux), statically linked, for GNU/Linux 2.6.30, not stripped
>> ./i686-nptl-linux-gnu/sys-root/sbin/ldconfig:
>>                   ELF 32-bit LSB executable, Intel 80386, version 1
>> (GNU/Linux), statically linked, for GNU/Linux 2.6.30, not stripped
>> ./i686-nptl-linux-gnu/sys-root/lib/libm-2.12.1.so:
>>   ELF 32-bit LSB shared object, Intel 80386, version 1 (GNU/Linux),
>> dynamically linked (uses shared libs), for GNU/Linux 2.6.30, not
>> stripped
>> ./i686-nptl-linux-gnu/sys-root/lib/libc-2.12.1.so:
>>   ELF 32-bit LSB shared object, Intel 80386, version 1 (GNU/Linux),
>> dynamically linked (uses shared libs), for GNU/Linux 2.6.30, not
>> stripped
>>
>> I have tried adding binutils-2.20.51 (snapshot) to my local version of
>> ct-ng, but this produced the same results.
>>
>> Does anyone have suggestions on how to (e)glibc to build as "(SYSV)"
>> and not "(GNU/Linux)"?
>>
>> -Bryan
>>
>
> I believe I have figured this out.
>
> We need the following patch for binutils 2.20.1:
> http://sourceware.org/ml/binutils/2010-02/msg00369.html
>
> and in the (e)glibc build script add: --disable-multi-arch
>
> -Bryan
>

Just curious if there are other things that need to be fixed before
static toolchain support can go in?
Or if there is more discussion/changes needed?
If there is anything I can help with, I am here.

-Bryan

--
For unsubscribe information see http://sourceware.org/lists.html#faq



More information about the crossgcc mailing list