[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: kernel build fails



Chris Jones wrote:
Hi,

I'm try to rebuild the 2.6.11 kernel using the instructions at this web page, mentioned in a recent post as a good guide.

http://crab-lab.zool.ohiou.edu/kevin/kernel-compilation-tutorial-en/

I'm using the src rpm

kernel-2.6.11-1.14_FC3.src.rpm

as the source, and have followed the instructions to the letter, using "i686" as my ARCH (the output from uname -p)

everything is OK until step 8

 > rpmbuild -bb --target=i686 ~/rpmbuild/SPECS/kernel-2.6.spec

.
.
.
.
+ cp -fv /home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i386.config /home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i586-smp.config /home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i586.config /home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i686-smp.config /home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i686.config .
`/home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i386.config' -> `./kernel-2.6.11-i386.config'
`/home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i586-smp.config' -> `./kernel-2.6.11-i586-smp.config'
`/home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i586.config' -> `./kernel-2.6.11-i586.config'
`/home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i686-smp.config' -> `./kernel-2.6.11-i686-smp.config'
`/home/jonesc/rpmbuild/SOURCES/kernel-2.6.11-i686.config' -> `./kernel-2.6.11-i686.config'
+ for i in '*.config'
+ mv kernel-2.6.11-i386.config .config
++ head -1 .config
++ cut -b 3-
+ Arch=
+ make ARCH= nonint_oldconfig
Makefile:448: /home/jonesc/rpmbuild/BUILD/kernel-2.6.11/linux-2.6.11/arch//Makefile: No such file or directory
make: *** No rule to make target `/home/jonesc/rpmbuild/BUILD/kernel-2.6.11/linux-2.6.11/arch//Makefile'. Stop.
error: Bad exit status from /var/tmp/rpm-tmp.52092 (%prep)



RPM build errors: Bad exit status from /var/tmp/rpm-tmp.52092 (%prep)


so - what am I doing wrong ?

cheers Chris


Hello Chris,

You are not doing anything wrong. The tutorial used to work just fine, but this latest kernel src rpm changed something. I rebuilt the
last several kernel rpms from kernel src rpms just fine but this latest one gave me the error you showed above. It took me a while to figure out what was wrong.


If you do a diff between

~/rpmbuild/BUILD/kernel-2.6.11/linux-2.6.11/.config

and

~/rpmbuild/BUILD/kernel-2.6.11/linux-2.6.11/configs/kernel-2.6.11-i686.config

you'll see that the difference is:

> # i386

The "i386" is missing and this is what causes the problem. If you customize your CONFIG with make xconfig like I did, after you save it your .config will still be missing the "i386" comment on the first
line.


So to get it to work, my workaround is to edit your .config file and put "i386" back on the first line of your .config file.

Then you will be able to build your kernel rpm successfully.

One more thing, even though your target arch is i686 (like mine was), you still need to put "i386" in your .config file.

--Kenny

--
Because words are imperfect, every generation rewrites itself.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]