Sunday, January 30, 2022

[SOLVED] Kernel build for CentOS 7: kernel-firmware not generated

Issue

I'm in the process of rebuilding the Linux kernel for Cent OS 7 to select a different preemption level.

My steps follow:

  • sudo yum install rpm-build redhat-rpm-config asciidoc hmaccalc perl-ExtUtils-Embed pesign xmlto audit-libs-devel binutils-devel elfutils-devel elfutils-libelf-devel ncurses-devel newt-devel numactl-devel pciutils-devel python-devel zlib-devel gcc patchutils bison make gcc redhat-rpm-config
  • mkdir -p ~/rpmbuild/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
  • echo '%_topdir %(echo $HOME)/rpmbuild' > ~/.rpmmacros
  • wget http://vault.centos.org/7.2.1511/updates/Source/SPackages/kernel-3.10.0-327.4.4.el7.src.rpm
  • rpm -i kernel-3.10.0-327.4.4.el7.src.rpm
  • cd ~/rpmbuild/SPECS
  • rpmbuild -bp --target=$(uname -m) kernel.spec
  • Kernel in BUILD configured and config file copied in SOURCES
  • rpmbuild -bb --with firmware --without kabichk --without debug --without debug-info --without doc --target=`uname -m` kernel.spec 2> build-err.log | tee build-out.log
  • rpmbuild -bb --with firmware --without kabichk --without debug --without debug-info --without doc --target=noarch kernel.spec 2> build-err.log | tee build-out.log

(--without kabichk is needed because the new preemption level somehow breaks the current ABI)

The problem is that the package kernel-firmware gets not generated. Any idea of what is missing ?


Solution

There doesn't appear to be a kernel-firmware package in CentOS 7 at all. And a quick search through the kernel spec file confirms that kernel-firmware doesn't appear anywhere in it.

There is a linux-firmware package though.

That package is built by the linux-firmware specfile.



Answered By - Etan Reisner
Answer Checked By - Robin (WPSolving Admin)