Disregard this note. I'm not sure it's valid.

I found the problem was with simply adding -pie to the "+link" rule in 
configparams in Glibc. Copying/replacing "+link-pie" rules/commands 
to "+link" solved this problem.

robert

On Friday October 9 2009 10:44:13 pm Robert Connolly wrote:
> I'm starting this thread as a note list. This is a bit different than
> the "hlfs to clfs builds" thread, that related to issues
> building /cross-tools and /tools from an hlfs host.
>
> I'm trying to harden x86_64 from the clfs chroot. I didn't harden /tools.
>
> For Glibc applications, like iconv_prog, to build
> with -fPIE -pie, "/tools/lib/gcc/whatever-unknown-linux-gnu/?.?.?/crtend.o"
> needs to be built with -fPIC... /tools GCC needs to be compiled with -fPIC.
>
> So:
> cp -vi gcc/config/i386/linux.h{,.orig}
> sed 's/^\(#define CC1_SPEC.*\)\("\)$/\1 %{fno-pic|fpic|fPIC:;:-fPIC}\2/' \
>     gcc/config/i386/linux.h.orig > gcc/config/i386/linux.h
> ... or
> cp -vi gcc/config/i386/x86-64.h{,.orig}
> sed 's/^\(#define CC1_SPEC.*\)\("\)$/\1 %{fno-pic|fpic|fPIC:;:-fPIC}\2/' \
>         gcc/config/i386/x86-64.h.orig > gcc/config/i386/x86-64.h
> ... or add -fPIC to CFLAGS for GCC
> ... or use all of the above.
>
> I doubt there will be more notes to add to this thread, but I'll add them
> if found.
>
> robert


Attachment: pgpbRSxygYvC5.pgp
Description: PGP signature

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

Reply via email to