[CentOS-docs] doco bug as to http://wiki.centos.org/HowTos/Custom_Kernel
R P Herrold
herrold at owlriver.com
Fri Aug 27 15:35:22 EDT 2010
and AJB kernel-2.6.35-3.bcat.src.rpm
[I see AlanBartlett as the last editor on that page]
I have installed the given ajb source rpm
kernel-2.6.35-3.bcat.src.rpm, and verified that it is intact:
[herrold at kernel-bleeder linux-2.6.35.i686]$ rpm -Vp ~/build/ajb/sources/kernel-2.6.35-3.bcat.src.rpm
warning: /home/herrold/build/ajb/sources/kernel-2.6.35-3.bcat.src.rpm:
Header V3 DSA signature: NOKEY, key ID baadae52
.....UGT config-2.6.35-i686
.....UGT config-2.6.35-i686-PAE
.....UGT config-2.6.35-x86_64
missing kernel.spec
missing linux-2.6.35.3.tar.bz2
[herrold at kernel-bleeder linux-2.6.35.i686]$ pwd
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i686
[herrold at kernel-bleeder linux-2.6.35.i686]$
The tarball and .spec are in the anticipated locales, and out
of scope here; userids [UGT] are expected to differ
[herrold at kernel-bleeder linux-2.6.35.i686]$ ls -l \
~/rpmbuild/SPECS/ ~/rpmbuild/SOURCES/kernel
/home/herrold/rpmbuild/SOURCES/kernel:
total 68064
-rw-r--r-- 1 herrold herrold 109943 Aug 21 13:08 config-2.6.35-i686
-rw-r--r-- 1 herrold herrold 109993 Aug 21 13:08 config-2.6.35-i686-PAE
-rw-r--r-- 1 herrold herrold 105624 Aug 21 13:08 config-2.6.35-x86_64
-rw-r--r-- 1 herrold herrold 69267320 Aug 21 13:02 linux-2.6.35.3.tar.bz2
/home/herrold/rpmbuild/SPECS/:
total 20
-rw-r--r-- 1 herrold herrold 15839 Aug 21 13:04 kernel.spec
[herrold at kernel-bleeder linux-2.6.35.i686]$
-------------
The wiki page notes:
| If you you do not intend to modify the distributed kernel
| configuration file you may omit this section, as long as you
| perform the equivalent of the final step:
|
| [user at host] $ cp \
| ~/rpmbuild/BUILD/kernel-2.6.18/linux-2.6.18.`uname -m`/configs/* \
| ~/rpmbuild/SOURCES
which is curious, because at this point in the outline in
section 2, ~/rpmbuild/BUILD/ should be empty
I suspect there has been a:
[herrold at kernel-bleeder ~]$ rpm -U \
~/build/ajb/sources/kernel-2.6.35-3.bcat.src.rpm
[herrold at kernel-bleeder ~]$ rpmbuild -bp \
~/rpmbuild/SPECS/kernel.spec
omitted here. Following on that assumption, I do those setps
and cd into the prepared directory
-------------
I follow the wiki outline branch involving using an existing
config file out of /boot/,
[user at host]$ cp /boot/config-`uname -r` .config
and run the suggested
make oldconfig
and perform the edit to the top of the resulting .config to
add the `uname -i ` comment on the first line
-------------
The outline falls of the tracks here. It suggests:
| Copy the .config file back to the configs/ directory. This is
| basically the opposite of the earlier copy command:
|
| [user at host]$ cp .config configs/kernel-2.6.18-`uname -m`[-type].config
[herrold at kernel-bleeder ~]$ find / -type d -name configs 2> /dev/null
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/microblaze/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/cris/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/sparc/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/mn10300/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/mips/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/x86/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/m32r/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/score/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/avr32/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/m68knommu/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/powerpc/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/parisc/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/xtensa/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/blackfin/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/arm/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/m68k/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/sh/configs
/home/herrold/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/ia64/configs
[herrold at kernel-bleeder ~]$
The problem here: several candidates to copy to are possible,
and although I assume an arch dependent choice is proper:
~/rpmbuild/BUILD/kernel-2.6.35/linux-2.6.35.i386/arch/x86/configs
the reader is left to wonder
-------------
The outline next goes off into .spec file edits, and does not
stop to roll and position a new tarball
I think some steps are missing that need to be done first:
cd ~/rpmbuild/BUILD/kernel-2.6.35
mv linux-2.6.35.i386 linux-2.6.35.3
tar cf linux-2.6.35.3.tar linux-2.6.35.3
bzip2 linux-2.6.35.3.tar
cp linux-2.6.35.3.tar.bz2 ~/rpmbuild/SOURCES
or such? The .spec file seems to key off of:
%define LKAver 2.6.35.3
-------------
So open questions working through the article are:
1. is there a missing preparatory rpm based unpack and
rpmbuild -bp
2. what is the proper place for the new .config,
taking into account the target arch
3. is there a missing directory rename and tarball
re-roll
-------------
Not unexpectedly, these are raised in the context of packaging
and getting to a non-root build of pathscale's pscnv 'gpgpu
module' as raised on another mailing list earlier this week
I raise them here [centos-docs ML] rather than adding QUERY in
the articles
-- Russ herrold
More information about the CentOS-docs
mailing list