Rob van Dam wrote:
> Rob,
>   
>> Thanks for the email although I don't think that's my problem. I had
>> already seen that post and discounted it as the command line to gcc is
>> even telling it to use PIC. The part that concerns me is that the
>> compiler is trying to write into a section of the lib file which is
>> marked readonly (well read only and executable).
>>
>> Thanks,
>> Brian.
>>   
>>     
> Hi Brian,
> When I do a readelf *-d* check a TEXTREL section is present:
> :/mnt/hlfs/sources/butterfly-build$ readelf -d 
> /mnt/hlfs/sources/butterfly-build/bfd/.libs/libbfd-2.17.so
>
> Dynamic section at offset 0x8b85c contains 25 entries:
>   Tag        Type                         Name/Value
>  0x00000001 (NEEDED)                     Shared library: [libssp.so.0]
>  0x00000001 (NEEDED)                     Shared library: [libc.so.0]
>  0x0000000e (SONAME)                     Library soname: [libbfd-2.17.so]
>  0x0000000c (INIT)                       0xf214
>  0x0000000d (FINI)                       0x782d4
>  0x00000004 (HASH)                       0x114
>  0x00000005 (STRTAB)                     0x43c4
>  0x00000006 (SYMTAB)                     0x14f4
>  0x0000000a (STRSZ)                      16133 (bytes)
>  0x0000000b (SYMENT)                     16 (bytes)
>  0x00000003 (PLTGOT)                     0x8b944
>  0x00000002 (PLTRELSZ)                   2968 (bytes)
>  0x00000014 (PLTREL)                     REL
>  0x00000017 (JMPREL)                     0xe67c
>  0x00000011 (REL)                        0x88c4
>  0x00000012 (RELSZ)                      23992 (bytes)
>  0x00000013 (RELENT)                     8 (bytes)
>  0x00000016 (TEXTREL)                    0x0
>  0x00000018 (BIND_NOW)                  
>  0x6ffffffb (FLAGS_1)                    Flags: NOW
>  0x6ffffffe (VERNEED)                    0x88a4
>  0x6fffffff (VERNEEDNUM)                 1
>  0x6ffffff0 (VERSYM)                     0x82ca
>  0x6ffffffa (RELCOUNT)                   1605
>  0x00000000 (NULL)                       0x0
>
> This could be an indication that -fPIE is being used, even when the 
> command line output tells something different.
>
> To be honest, this is a little too much for me, so you could consider 
> this as a shot in the dark.
>
>
> Rob
>   
Rob,

I should have asked in my last email, but have you managed to compile
the butterfly toolchain without a problem?

Cheers,
Brian.
-- 
http://linuxfromscratch.org/mailman/listinfo/hlfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to