[CentOS] Custom kernel RPM/SRPM

Luis Alejandro Cazzola cazzola_luis at yahoo.com.ar
Thu Nov 17 12:44:54 UTC 2005

can you explain more in details the methos to do the sourcecode to then 
compiling a custom kernel.
i get the kernel- from centos mirrors,
i'd installed
then edit spec (1 to build)
then rpmbuild -ba --target=i686 /path/to/spec ( i want to know whay i have 
to do this if the only thing that i want its the source kernel)
OK, at this time my pc was compiling 10 hours ( i dont know what are 
compiling and what for ?, i dont need any binary i need the kernel sources)
10 hours later i had a lot of rpm, one sources, same devel, an other , so i 
only want the sources so i did:
rpm -ivh kernel-sourcecodexxxx.rpm , succesfully, but i dont get a 
"usr/src/linux-xxx" folder, why? , instead i get a folder in 
/usr/src/kernels/ with the number of the kernels sources ok, so i open this 
folder and did:
mrproper , at the end its say that dont have the rule "xx"
and if i do : make help, the list of rules broke at the rpm-pkg rule, and 
say the same : no rule "xx"
what means that?
somebody knows? or somebody have an explain method to do an correct kernel 
compilation from the x.src.rpm package , i would like that explain what for 
are each command and argument.
i will wainting for some response.

lucho from argentina

----- Original Message ----- 
From: "Giovanni P. Tirloni" <gpt at tirloni.org>
To: "CentOS mailing list" <centos at centos.org>
Sent: Thursday, November 17, 2005 9:03 AM
Subject: [CentOS] Custom kernel RPM/SRPM

> Hi,
>  I've built customs kernels from the SRPMs with the following:
>   rpmbuild -bp --target=i686 /path/to/spec
>   cd /usr/src
>   ln -s /usr/src/redhat/BUILD/kernel-x.y.z/linux-x.y.z linux
>   cd linux
>   make oldconfig
>   make menuconfig
>   make all
>   make modules
>   make modules_install
>  And it works just fine. The problem now is that I think installing that 
> way isn't "cool": I wan to build my own custom kernel RPM/SRPM.
>  I thought about doing a "rpmbuild -bp" and change the options. Then a 
> "rpmbuild -bc --short-circuit" and a "rpmbuild -bi --short-circuit".
>  What's the correct way of doing this?
> Thanks in advance,
> -- 
> Giovanni P. Tirloni
> http://blog.tirloni.org
> _______________________________________________
> CentOS mailing list
> CentOS at centos.org
> http://lists.centos.org/mailman/listinfo/centos 

More information about the CentOS mailing list