LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-06-2004, 06:17 PM   #1
Dancingsalad
LQ Newbie
 
Registered: Jan 2004
Location: Connecticut
Distribution: Fedora Core 1
Posts: 6

Rep: Reputation: 0
error compiling kernel 2.6.2 (GCC too old??)


hello hello...first time poster

i've been trying out linux to try to educate myself...so far i have a dual boot on my P3 450 mhz with rh9 and winxp

i also have anotherr box that i dug out of the closet and managed to install rh 6.2 on it (Pentium 133 mhz...16 mb ram 1.1 gb HDD)

after learning the layout and other things i decided i should try to compile a kernel (using the P133 as a guinea pig)

i downloaded the 2.6.2 tar.bz2 and configured the whole thing with make menuconfig

saved the config file then tried to compile it (i have the help of a book Linux For Windows Addicts: A 12 Step Program

it told me to:
$ make dep ; make clean ; make bzimage

i think i got thru the first 2, but then when it went to compile i got this output and i'm stumped as to what to do:

(exactly as it appeared on my screen):

CC init/main.o
init/main.c:67: #error Sorry, your GCC is too old. It builds incorrect kernels.
make[1]: *** [init/main.o] Error 1
make: *** [init] Error 2

...and back to the regular prompt

any ideas? is it because my distro is too old and i'm using the newest kernel?

any ideas you guys can bounce off me would be much appreciated, thanks!

-jeremy
 
Old 02-06-2004, 06:20 PM   #2
h/w
Senior Member
 
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286

Rep: Reputation: 46
hey.
what does "gcc -v" give you?

also the steps you are following are for the 2.4
u dont need make dep/bzimage

just make menuconfig, make, make modules_install.
 
Old 02-06-2004, 09:04 PM   #3
Dancingsalad
LQ Newbie
 
Registered: Jan 2004
Location: Connecticut
Distribution: Fedora Core 1
Posts: 6

Original Poster
Rep: Reputation: 0
gcc -v gives me:

-Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/specs
-gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)

using make gave me gave the same GCC error

using module_install gave me a different error...but i think i need to be root...ill worry about that one after i figure out the GCC thing
 
Old 02-06-2004, 09:09 PM   #4
h/w
Senior Member
 
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286

Rep: Reputation: 46
right, u need to get gcc.3.xx

i believe thats a 2.6 requirement?
 
Old 02-06-2004, 09:09 PM   #5
h/w
Senior Member
 
Registered: Mar 2003
Location: New York, NY
Distribution: Debian Testing
Posts: 1,286

Rep: Reputation: 46
and yes, "make modules_install" is the ONLY command which u need to be root for.
the previous two can be done as normal user.
 
Old 02-07-2004, 05:05 PM   #6
urka58
Member
 
Registered: Nov 2003
Distribution: slackware 14
Posts: 540

Rep: Reputation: 32
You also need module_init_tools to be installed before compiling a 2.6 kernel series. Not sure RH9 comes ready for the new kernel series. RH6 doesn't for sure.
Hope this helps
Ciao
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Error Compiling GCC (1st Pass) in LFS 6.0 TGWDNGHN Linux From Scratch 1 06-30-2005 09:57 PM
Kernel compiling: gcc-3.3 is 586, should be gcc-3.3 386 Erik Plaggenmar Linux - Software 0 10-01-2004 12:38 PM
gcc 3.3.2 segfaults when compiling 2.4.23 kernel Azmeen Slackware 5 11-29-2003 08:53 PM
GCC error when compiling it for LFS safrout Linux From Scratch 1 06-14-2003 07:16 AM
gcc error while compiling gawk iceman47 Linux From Scratch 2 03-04-2003 01:12 PM


All times are GMT -5. The time now is 03:48 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration