LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 05-04-2011, 01:50 AM   #1
just.centos
LQ Newbie
 
Registered: May 2011
Posts: 8

Rep: Reputation: 0
Question error when compile kernel


hello
when i run "make oldconfig" or "make bzImage" or ...
to compile my newkernel after patch gresecurity,give me this error:
HOSTCC scripts/basic/fixdep
cc1: error: unrecognized command line option "-Wno-empty-body"
make[1]: *** [scripts/basic/fixdep] Error 1
make: *** [scripts_basic] Error 2

thanks for any ideas.
 
Old 05-04-2011, 03:16 AM   #2
vdx
Member
 
Registered: Aug 2007
Location: The Greate INDIA
Distribution: CentOS, RHEL, Fedora
Posts: 102

Rep: Reputation: 24
I appreciate If u post ur kernel ver & the patch u r applying.
 
Old 05-04-2011, 06:45 AM   #3
just.centos
LQ Newbie
 
Registered: May 2011
Posts: 8

Original Poster
Rep: Reputation: 0
Question

Quote:
Originally Posted by vdx View Post
I appreciate If u post ur kernel ver & the patch u r applying.

kernel; linux-2.6.32.39.tar.bz2
patch: grsecurity-2.2.2-2.6.32.39-201104301754.patch

my cmd:

root@server [~]# cd /root
root@server [~]# wget http://www.kernel.org/pub/linux/kern....32.39.tar.bz2
root@server [~]# wget http://grsecurity.net/stable/grsecur...04301754.patch
root@server [~]# tar -vxjf linux-2.6.32.39.tar.bz2
root@server [~]# patch -p0 < grsecurity-2.2.2-2.6.32.39-201104301754.patch
root@server [~]# mv linux-2.6.32.39 linux-2.6.32.39-grsec
root@server [~]# ln -s linux-2.6.32.39-grsec/ linux
root@server [~/linux]# cd linux
root@server [~/linux]# cp /boot/config-`uname -r` .config
root@server [~/linux]# make oldconfig
HOSTCC scripts/basic/fixdep
cc1: error: unrecognized command line option "-Wno-empty-body"
make[1]: *** [scripts/basic/fixdep] Error 1
make: *** [scripts_basic] Error 2
 
Old 05-04-2011, 12:31 PM   #4
just.centos
LQ Newbie
 
Registered: May 2011
Posts: 8

Original Poster
Rep: Reputation: 0
Unhappy

gcc version: gcc-4.1.2-50.el5.x86_64
kernel version: Linux 2.6.18-238.9.1.el5

new version that i want to install:
kernel: linux-2.6.32.39
patch: grsecurity-2.2.2-2.6.32.39-201104301754.patch
my OS version: centos 5.6 64bit
 
Old 05-05-2011, 01:39 AM   #5
vdx
Member
 
Registered: Aug 2007
Location: The Greate INDIA
Distribution: CentOS, RHEL, Fedora
Posts: 102

Rep: Reputation: 24
Smile

You having the gcc which does not support this switch(-Wno-empty-body)

I can successfully compile the same with the gcc-4.5.1

Either update ur gcc or simply remove the option from make file.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Kernel compile error _InTeNsDoWn_ Linux - Newbie 10 04-15-2006 12:42 PM
Kernel Compile error JTR Debian 2 08-03-2005 12:54 PM
Kernel compile error rael_kid Linux - Newbie 14 04-25-2005 11:41 AM
Error during the kernel (2.6.10) compile. Whynot Debian 1 03-03-2005 07:34 PM
Compile kernel error Lokii13 Linux - Newbie 1 02-26-2003 05:26 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 06:03 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration