LinuxQuestions.org
Have you heard the LinuxQuestions.org Podcast?
Go Back   LinuxQuestions.org > Forums > Linux > Linux - Newbie
User Name
Password
Linux - Newbie This 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
 
Thread Tools
Old 11-16-2009, 01:39 AM   #1
viswa_4
LQ Newbie
 
Registered: Nov 2009
Posts: 5
Thanked: 0
problem in making Linux kernel


[Log in to get rid of this advertisement]
[root@localhost linux-2.6.10-mvl40_fp]# make vmlinux
CHK include/linux/version.h
CC scripts/mod/empty.o
mv: cannot stat `scripts/mod/.tmp_empty.o': No such file or directory
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2
.................
i am new to linux..i think path settings are right.can u suggest wat might be the error .thanks in advance.
linuxfedora viswa_4 is offline     Reply With Quote
Old 11-16-2009, 03:01 AM   #2
vishesh
Member
 
Registered: Feb 2008
Location: india
Distribution: Fedora,RHEL,Ubuntu
Posts: 262
Thanked: 24
I don't able to get your problem exactly, but i think you should follow following steps

step1. Move into kernel source directory like 'cd /usr/local/src/<kernel source director>'
step2. execute 'make menuconfig' command to select your options.
step3. execute 'make' to compile the kernel
step4. execute 'make modules_install' to install modules in /lib/modules
step5. execute 'make install ' to transfer compiled kernel to /boot pertition

thanks
windows_xp_2003 vishesh is offline     Reply With Quote
Old 11-16-2009, 03:57 AM   #3
viswa_4
LQ Newbie
 
Registered: Nov 2009
Posts: 5
Thanked: 0

Original Poster
my problem is
i am building linux kernel (VMLINUX)
so i have been cd to source dir
$make clean (i have done)
$make vmlinux
i get the following error.

CHK include/linux/version.h
CC scripts/mod/empty.o
mv: cannot stat `scripts/mod/.tmp_empty.o': No such file or directory
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2

what does the error mean mv:cannot stat
my gcc version is 4.3.0 and there is a file called empty.c
linuxfedora viswa_4 is offline     Reply With Quote
Old 11-16-2009, 04:11 AM   #4
vishesh
Member
 
Registered: Feb 2008
Location: india
Distribution: Fedora,RHEL,Ubuntu
Posts: 262
Thanked: 24
why 'make vmlinux'?

Once, try my given steps and let me know the result.
Also remember to do this with root login.

Thanks
windows_xp_2003 vishesh is offline     Reply With Quote
Old 11-16-2009, 04:44 AM   #5
viswa_4
LQ Newbie
 
Registered: Nov 2009
Posts: 5
Thanked: 0

Original Poster
i am in root login only.
1.done make menuconfig and changed my settings.saved the configuration.
2.make.giving the following error.
[root@localhost linux-2.6.10-mvl40_fp]# make
CHK include/linux/version.h
CC scripts/mod/empty.o
mv: cannot stat `scripts/mod/.tmp_empty.o': No such file or directory
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2
.
3.make,make modules all give the above error.
Plz suggest.
linuxfedora viswa_4 is offline     Reply With Quote
Old 11-16-2009, 07:21 AM   #6
viswa_4
LQ Newbie
 
Registered: Nov 2009
Posts: 5
Thanked: 0

Original Poster
problem with dependencies.not able to figure out.

[root@localhost linux-2.6.10-mvl40_fp]# make
CHK include/linux/version.h
CC scripts/mod/empty.o
fixdep: scripts/mod/.empty.o.d: No such file or directory
make[2]: *** [scripts/mod/empty.o] Error 2
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2
linuxfedora viswa_4 is offline     Reply With Quote
Old 11-16-2009, 08:10 AM   #7
JohnGraham
Member
 
Registered: Oct 2009
Posts: 61
Thanked: 12
Did you run 'make mrproper' before you built the kernel? (even if you've just downloaded it)

This will remove your .config file though, so make sure you move it out of the kernel source tree first if you want to save it.

John G
linuxubuntu JohnGraham is offline     Reply With Quote
Old 11-16-2009, 08:16 AM   #8
mudangel
Member
 
Registered: May 2008
Location: Ohio
Distribution: Slackware
Posts: 120
Thanked: 7
Try: 'make (old,x,menu)config, make, make modules, make modules_install'...where are you getting 'make vmlinux'?
linuxslackware mudangel is offline     Reply With Quote
Old 11-17-2009, 02:04 AM   #9
viswa_4
LQ Newbie
 
Registered: Nov 2009
Posts: 5
Thanked: 0

Original Poster
these normal steps are ok.i am clear with that.
but i am doing for MIPS board.
if u have normal kernel code u can browse through /linux/scripts/mod
please open the Makefile in that folder.
even for normal make error is coming.

CHK include/linux/version.h
CC scripts/mod/empty.o
mv: cannot stat `scripts/mod/.tmp_empty.o': No such file or directory
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2
linuxfedora viswa_4 is offline     Reply With Quote
Old 11-17-2009, 03:01 AM   #10
gauravholey
LQ Newbie
 
Registered: May 2009
Posts: 26
Thanked: 0
hi dear,

In my opinion you should try and go through this link http://www.howtoforge.net/kernel_compilation_fedora_p2 ,really helpful in many ways...kudos to these people..try it....

njoy,
gaurav holey
windows_xp_2003 gauravholey is offline     Reply With Quote

Reply

Bookmarks


Thread Tools

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
Making the Linux Kernel a Project in Eclipse droneprime Linux - Kernel 4 10-30-2009 04:16 PM
problem in making zImage of linux kernel 2.6.26.3 zahidul Linux - Newbie 2 09-24-2008 04:46 AM
problem after making kernel on a dell 630 inspiron with FC4 ulssneos Linux - Laptop and Netbook 3 05-04-2006 12:17 AM
kernel making me quit linux DAChristen29 Linux - Software 8 12-31-2002 02:24 AM


All times are GMT -5. The time now is 07:17 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
RSS2  LQ Podcast
RSS2  LQ Radio
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration