Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 415185 - sys-devel/gcc-4.5 and later: broken pie linking on FreeBSD
Summary: sys-devel/gcc-4.5 and later: broken pie linking on FreeBSD
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Toolchain Maintainers
URL: http://gcc.gnu.org/ml/gcc-patches/201...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-08 22:44 UTC by Alexis Ballier
Modified: 2012-05-11 08:49 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexis Ballier gentoo-dev 2012-05-08 22:44:52 UTC
Not all of our patch to previous releases has been merged in gcc 4.5 but the whole patch was dropped.

One part of it was making it use the right crt*.o files for pie executables. While, on x86, it doesnt cause errors but only renders pie almost useless, on amd64 this becomes an error and causes me problems.

See:
http://gcc.gnu.org/ml/gcc-patches/2012-05/msg00555.html

could you please add it to our patchset for current releases ? thanks!
Comment 1 Alexis Ballier gentoo-dev 2012-05-08 22:47:35 UTC
on amd64 (out of my memory) errors are: gcc -pie -fPIC -fPIE foo.c
Error: cannot make relocation against for /usr/.../crt1.o ... recompile -fPIC

with the patch it works fine.
Comment 2 SpanKY gentoo-dev 2012-05-10 03:10:02 UTC
what versions of gcc exactly do you want this merged into ?
Comment 3 Alexis Ballier gentoo-dev 2012-05-10 15:20:43 UTC
(In reply to comment #2)
> what versions of gcc exactly do you want this merged into ?

starting from latest ~arch up to current I'd say, today that'll mean 4.5.3, 4.6.3 (and 4.7 at some point). if 4.6 goes to ~arch, i dont care about 4.5; what is important to me is that i get a working compiler by 'emerge -1 gcc' so that i can continue keywording packages that rely on pie (eg cups).
Comment 4 SpanKY gentoo-dev 2012-05-11 08:47:47 UTC
i've queued it in all 4.5.x and 4.6.x dirs, and released it in 4.5.3 and 4.6.3

http://sources.gentoo.org/gentoo/src/patchsets/gcc/4.6.3/gentoo/92_all_freebsd-pie.patch?rev=1.1
Comment 5 SpanKY gentoo-dev 2012-05-11 08:49:38 UTC
should be all set now in the tree; thanks for the report!

Commit message: Push out FreeBSD PIE fix
http://sources.gentoo.org/sys-devel/gcc/gcc-4.5.3-r2.ebuild?r1=1.13&r2=1.14
http://sources.gentoo.org/sys-devel/gcc/gcc-4.6.3.ebuild?r1=1.2&r2=1.3