GCC Plugin issue for kernel 3.14.17

Discuss usability issues, general maintenance, and general support issues for a grsecurity-enabled system.

GCC Plugin issue for kernel 3.14.17

Postby atul.singh008 » Wed Jan 07, 2015 3:37 am

Hi,

I am trying to build kernel 3.14.17 using grsecurity patach(grsecurity-3.0-3.14.27-201501042018.patch) for ARM.
I have enable the plugin support for the GCC using enable plugin.

[atulk@localhost linux-3.14.17]$ $CC -print-file-name=plugin
/home/atulk/test/ARM_plugin/sysroots/i686-pokysdk-linux/usr/bin/arm-pokymllibv5te-linux-gnueabi/../../lib/arm-pokymllibv5te-linux-gnueabi/gcc/arm-pokymllibv5te-linux-gnueabi/4.9.1/plugin

The Host GCC version i am using is:-
gcc version 4.8.2 20131017 (Red Hat 4.8.2-1) (GCC)


Code: Select all
[atulk@localhost linux-3.14.17]$ sh -x scripts/gcc-plugin.sh g++ g++ $CC
++ dirname scripts/gcc-plugin.sh
+ srctree=scripts
++ arm-pokymllibv5te-linux-gnueabi-gcc -print-file-name=plugin
+ gccplugins_dir=/home/atulk/test/ARM_plugin/sysroots/i686-pokysdk-linux/usr/bin/arm-pokymllibv5te-linux-gnueabi/../../lib/arm-pokymllibv5te-linux-gnueabi/gcc/arm-pokymllibv5te-linux-gnueabi/4.9.1/plugin
++ g++ -E - -o /dev/null -Iscripts/../tools/gcc -I/home/atulk/test/ARM_plugin/sysroots/i686-pokysdk-linux/usr/bin/arm-pokymllibv5te-linux-gnueabi/../../lib/arm-pokymllibv5te-linux-gnueabi/gcc/arm-pokymllibv5te-linux-gnueabi/4.9.1/plugin/include
+ plugincc='<stdin>:3:2: warning: #warning g++ CXX [-Wcpp]'
+ '[' 0 -ne 0 ']'
+ case "$plugincc" in
++ g++ -c -x c++ -std=gnu++98 - -fsyntax-only -Iscripts/../tools/gcc -I/home/atulk/test/ARM_plugin/sysroots/i686-pokysdk-linux/usr/bin/arm-pokymllibv5te-linux-gnueabi/../../lib/arm-pokymllibv5te-linux-gnueabi/gcc/arm-pokymllibv5te-linux-gnueabi/4.9.1/plugin/include
+ plugincc=
+ '[' 0 -eq 0 ']'
+ echo g++
g++
+ exit 0


But while building kernel i am getting error as:-
Code: Select all
cc1: error: cannot load plugin /home/atulk/test/linux-3.14.17/tools/gcc/colorize_plugin.so
/home/atulk/test/linux-3.14.17/tools/gcc/colorize_plugin.so: undefined symbol: _ZN8opt_pass5cloneEv
cc1: error: cannot load plugin /home/atulk/test/linux-3.14.17/tools/gcc/structleak_plugin.so
/home/atulk/test/linux-3.14.17/tools/gcc/structleak_plugin.so: undefined symbol: _ZN8opt_pass5cloneEv
cc1: error: cannot load plugin /home/atulk/test/linux-3.14.17/tools/gcc/latent_entropy_plugin.so
/home/atulk/test/linux-3.14.17/tools/gcc/latent_entropy_plugin.so: undefined symbol: _Z24gt_ggc_mx_lang_tree_nodePv
cc1: error: cannot load plugin /home/atulk/test/linux-3.14.17/tools/gcc/randomize_layout_plugin.so
/home/atulk/test/linux-3.14.17/tools/gcc/randomize_layout_plugin.so: undefined symbol: _ZN8opt_pass5cloneEv
make[1]: *** [kernel/bounds.s] Error 1


Please let me know if i am missing something.
Thanks for your help in advance.

Regards,
Atul
atul.singh008
 
Posts: 12
Joined: Wed Dec 31, 2014 5:48 am

Return to grsecurity support