LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 08-20-2005, 12:08 PM   #1
SonicGT
Member
 
Registered: Oct 2004
Posts: 38

Rep: Reputation: 15
Trying to recompile kernel but config's not working.


Well, I'm trying to recompile the kernel so that I can get rivafb support so that I couls have a bootsplash. However, when I try to run make xconfig, it didn't work. same for make menuconfig. Here's what I got:

Code:
user@hostname:/usr/src/kernel-source-2.6.8$ make xconfig
  HOSTCC  scripts/kconfig/mconf.o
scripts/kconfig/mconf.c:91: error: static declaration of 'current_menu' followsnon-static declaration
scripts/kconfig/lkc.h:63: error: previous declaration of 'current_menu' was here
make[1]: *** [scripts/kconfig/mconf.o] Error 1
make: *** [xconfig] Error 2
user@hostname:/usr/src/kernel-source-2.6.8$ make menuconfig
  HOSTCC  scripts/kconfig/mconf.o
scripts/kconfig/mconf.c:91: error: static declaration of 'current_menu' followsnon-static declaration
scripts/kconfig/lkc.h:63: error: previous declaration of 'current_menu' was here
make[1]: *** [scripts/kconfig/mconf.o] Error 1
make: *** [menuconfig] Error 2
I'm using Debian testing and as you can see, a 2.6.8 kernel.
 
Old 08-20-2005, 12:39 PM   #2
PenguinPwrdBox
Member
 
Registered: Oct 2003
Location: /illinois/chicago
Distribution: Slackware/Gentoo/FC/RHEL
Posts: 568

Rep: Reputation: 30
Try going into this file:

/usr/src/kernel-source-2.6.8/scripts/kconfig/mconf.c

and commenting out line 91.
Then run it again.
If that doesn't work - uncomment 91 - and comment 63.

BTW - to "comment" is to put a hash (#) at the beginning of the line
 
Old 08-20-2005, 03:09 PM   #3
SonicGT
Member
 
Registered: Oct 2004
Posts: 38

Original Poster
Rep: Reputation: 15
Thanks, though now I see that it's quite an obvious solution. Maybe I should of looked at the error before posting.

EDIT: Well, Ok, now I'm getting this when I actually try to compile the kernel:
Code:
make[1]: Entering directory `/usr/src/kernel-source-2.6.8'
  SPLIT   include/linux/autoconf.h -> include/config/*
  CC      arch/i386/kernel/asm-offsets.s
In file included from include/asm/thread_info.h:16,
                 from include/linux/thread_info.h:21,
                 from include/linux/spinlock.h:12,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:7,
                 from arch/i386/kernel/asm-offsets.c:7:
include/asm/processor.h:87: error: array type has incomplete element type
make[2]: *** [arch/i386/kernel/asm-offsets.s] Error 1
make[1]: *** [arch/i386/kernel/asm-offsets.s] Error 2
make[1]: Leaving directory `/usr/src/kernel-source-2.6.8'
make: *** [stamp-kernel-configure] Error 2
I checked processor.h, and the area with the offending line is this:
Code:
/*
 * capabilities of CPUs
 */

extern struct cpuinfo_x86 boot_cpu_data;
extern struct cpuinfo_x86 new_cpu_data;
extern struct tss_struct init_tss[NR_CPUS];
It's the third extern struct. Do you think I can just comment the line out, or will it need more drastic measures?

P.S. You can really use the hash mark for commenting instead of /*foo*/ in a C file?

Last edited by SonicGT; 08-20-2005 at 03:52 PM.
 
Old 08-20-2005, 06:25 PM   #4
PenguinPwrdBox
Member
 
Registered: Oct 2003
Location: /illinois/chicago
Distribution: Slackware/Gentoo/FC/RHEL
Posts: 568

Rep: Reputation: 30
I would download another source package and try again. I've never been one for fixing other peoples coding errors. Do report this, though - and let them figure out if it is a valid bug - instead of just something on your machine (gcc version - etc) - unless you are pretty adventurous...
 
Old 08-21-2005, 08:51 AM   #5
SonicGT
Member
 
Registered: Oct 2004
Posts: 38

Original Poster
Rep: Reputation: 15
Starting over is always a nice idea.

Ok, I think I will start over. Maybe I messed up somewhere and because of it caused this to happen. I might try using that guide to recompiling that's a sticky in the Debian forum here.

Of course, I first have to fix my messed up lilo. conf
 
Old 08-21-2005, 09:47 AM   #6
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,082

Rep: Reputation: 299Reputation: 299Reputation: 299
BTW, a # is not a comment for C source code as it would be for Perl or bash, which is part of the reason why that didn't work. Instead you would enclose the line as follows /* line */.

What version of gcc are you using? If you're using gcc 4 try installing an older version, as gcc 4 does some things differently and has a few issues since it's quite a bit stricter about enforcing some language rules than gcc 3 was.
 
Old 08-21-2005, 09:23 PM   #7
SonicGT
Member
 
Registered: Oct 2004
Posts: 38

Original Poster
Rep: Reputation: 15
Yep, the problem was that gcc was too new of a version, so I found a way to fix it so it uses the old one. So yes, my kernel was compiled. However, I still don't have a bootsplash. I checked and vesafb did load. Is it because I made the options in lilo.conf wrong? Here's my lilo.conf now:
Code:
boot=/dev/hda
map=/boot/map
install=/boot/boot.b
compact
prompt
timeout=50
default=Debian
image=/boot/vmlinuz-2.6.8-custom
	label=Debian
	root=/dev/hda1
	initrd= /boot/initrd.img-2.6.8-custom
	read-only
	append="video=vesafb:mtrr,ywrap,1024x768-32@85
image=/boot/vmlinuz-2.6.8-2-686
	label=DebianOld
	root=/dev/hda1
	initrd=/boot/initrd.img-2.6.8-2-686
	read-only
 
Old 08-22-2005, 11:05 AM   #8
SonicGT
Member
 
Registered: Oct 2004
Posts: 38

Original Poster
Rep: Reputation: 15
Ok, I'm bumping this up now, for I think I added the last comment way too late at night.
 
Old 08-23-2005, 12:36 AM   #9
Axo
Member
 
Registered: May 2003
Distribution: Debian
Posts: 142

Rep: Reputation: 16
install=/boot/boot.b ?
Going Graphical
 
Old 08-25-2005, 04:39 PM   #10
TimmyP
Member
 
Registered: Dec 2003
Location: Newark, DE
Distribution: Debian "sarge"
Posts: 50

Rep: Reputation: 15
SonicGT,

i'm having the same problem you were having, and when i last tried to downgrade my gcc i managed to delete gnome and left quite a few packages in my system unusable.

how did you manage to do it?

TimmyP
 
Old 08-25-2005, 06:12 PM   #11
SonicGT
Member
 
Registered: Oct 2004
Posts: 38

Original Poster
Rep: Reputation: 15
Wonder how that happened...all I jused was Synaptic's Force Version feature to downgrade and from there it worked fine...

At least that's what I think I did.
 
Old 08-25-2005, 08:01 PM   #12
TimmyP
Member
 
Registered: Dec 2003
Location: Newark, DE
Distribution: Debian "sarge"
Posts: 50

Rep: Reputation: 15
ah, i'm mostly an aptitude guy...i'll have to give synaptec another try. what i did though was to go to debian.org and download the lower version .deb package and install it with dpkg.

i don't remember what i did before...

it seems to me though that etch seems to be a bit more unstable than sid right now. there are a lot of packages (like alsa-utils for example) that the current version in testing is not compatable with other major testing software (like alsa-utils and gnome)
 
  


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
get USB stick working - recompile kernel?? ditch* Linux - Newbie 8 08-02-2005 04:16 AM
Syanptics touchpad not working after recompile of kernel microsoft/linux Linux - Laptop and Netbook 13 02-18-2005 09:23 AM
Modem not working after kernel recompile blk96gt Slackware 3 07-28-2004 02:47 PM
Mouse not working after kernel recompile. phekno Linux - Newbie 2 12-03-2003 07:50 PM
kernel recompile not working tokyo-jamie Linux - General 8 09-02-2003 09:35 PM


All times are GMT -5. The time now is 11:57 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration