Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 501308 - sys-kernel/hardened-sources-3.2.54-r9 with sys-devel/gcc-4.5.4 - .../tools/gcc/randomize_layout_plugin.c:897:34: error: ‘PLUGIN_FINISH_DECL’ undeclared
Summary: sys-kernel/hardened-sources-3.2.54-r9 with sys-devel/gcc-4.5.4 - .../tools/gc...
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Hardened (show other bugs)
Hardware: IA64 Linux
: Normal normal
Assignee: Anthony Basile
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-14 15:14 UTC by Dennis Schridde
Modified: 2014-09-14 00:32 UTC (History)
4 users (show)

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


Attachments
build.log (hardened-sources-3.2.54-r9.build.log,4.04 KB, text/plain)
2014-02-14 15:14 UTC, Dennis Schridde
Details
emerge --info (emerge.info,4.68 KB, text/plain)
2014-02-14 15:14 UTC, Dennis Schridde
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dennis Schridde 2014-02-14 15:14:18 UTC
Created attachment 370400 [details]
build.log

/usr/src/linux-3.2.54-hardened-r9/tools/gcc/randomize_layout_plugin.c: In function ‘plugin_init’:
/usr/src/linux-3.2.54-hardened-r9/tools/gcc/randomize_layout_plugin.c:897:34: error: ‘PLUGIN_FINISH_DECL’ undeclared (first use in this function)
/usr/src/linux-3.2.54-hardened-r9/tools/gcc/randomize_layout_plugin.c:897:34: note: each undeclared identifier is reported only once for each function it appears in

# gcc-4.5.4 --version
gcc-4.5.4 (Gentoo Hardened 4.5.4 p1.2, pie-0.4.7) 4.5.4
Comment 1 Dennis Schridde 2014-02-14 15:14:37 UTC
Created attachment 370402 [details]
emerge --info
Comment 2 Dennis Schridde 2014-02-23 01:41:44 UTC
Persists in sys-kernel/hardened-sources-3.2.55-r1:
/usr/src/linux-3.2.55-hardened-r1/tools/gcc/randomize_layout_plugin.c: At top level:
/usr/src/linux-3.2.55-hardened-r1/tools/gcc/randomize_layout_plugin.c:18:2: error: #error "The RANDSTRUCT plugin requires GCC 4.6.4 or newer."
/usr/src/linux-3.2.55-hardened-r1/tools/gcc/randomize_layout_plugin.c: In function ‘plugin_init’:
/usr/src/linux-3.2.55-hardened-r1/tools/gcc/randomize_layout_plugin.c:901:34: error: ‘PLUGIN_FINISH_DECL’ undeclared (first use in this function)
/usr/src/linux-3.2.55-hardened-r1/tools/gcc/randomize_layout_plugin.c:901:34: note: each undeclared identifier is reported only once for each function it appears in

GCC 4.6 and newer is broken on ia64 (bug #447754).
Comment 3 Anthony Basile gentoo-dev 2014-02-24 23:26:24 UTC
If you disable the plugins, does it work on ia64?
Comment 4 PaX Team 2014-02-25 02:49:53 UTC
where's the bug here? the plugin clearly documents its minimal requirement (the FINISH_DECL event callback was unfortunately never backported to gcc 4.5, despite my explicit request in their bugzilla: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41757) so either you use a new enough gcc or disable RANDSTRUCT :). also given how simple the patch is, perhaps the gentoo toolchain guys can be convinced to backport it to 4.5?
Comment 5 Dennis Schridde 2014-02-25 19:37:42 UTC
(In reply to PaX Team from comment #4)
> either you use a new enough gcc or disable RANDSTRUCT

Given that >=sys-devel/gcc-4.6 is unable to build bootable kernels (s.a.), I guess the only option is to make the plugin depend on !ia64. (Or backport support for finish-decl.)