LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   how to build for a new version (https://www.linuxquestions.org/questions/linux-kernel-70/how-to-build-for-a-new-version-4175619155/)

DBabo 12-07-2017 05:29 PM

how to build for a new version
 
Gents,
how do i go about building a kernel from src rpm for rawhide mainline if my current system is not "rawhide" ( it is f25 )?
Objective:
i want to try a new kernel on the current system, but need to make a few changes to it's params.

this is the script i use to adjust various params on the _current_ version:

Code:

#!/bin/sh
#4.15.0-0.rc2.git0.1.fc28.src.rpm

CWD=$(pwd)

num=4.15
fullish_num=${num}.0
full_num=${fullish_num}-0
src=kernel-${full_num}.rc2.git0.1.fc28.src.rpm

echo "Getting source for the kernel .. "
cd ~
#dnf download --source kernel

cd ~/rpmbuild/ && rm -rf ./*  &&
rpmdev-setuptree && cp -v ~/Downloads/kernel* ~/rpmbuild/ &&
rpm -Uhv ${src} && cd ~/rpmbuild/SPECS &&

rpmbuild -bp --target=$(uname -m) kernel.spec &&

cd ~/rpmbuild/BUILD/kernel-${num}.fc28/linux-${full_num}.fc28.x86_64/ &&
cp ./configs/kernel-${fullish_num}-x86_64.config ./.config


echo "Sleeping"
sleep 10
make menuconfig

following this script i now get:
Code:

Getting source for the kernel ..
'/home/az/Downloads/kernel-4.15.0-0.rc2.git0.1.fc28.src.rpm' -> '/home/az/rpmbuild/kernel-4.15.0-0.rc2.git0.1.fc28.src.rpm'
Updating / installing...
  1:kernel-4.15.0-0.rc2.git0.1.fc28
warning: user mockbuild does not exist - using root
warning: group mockbuild does not exist - using root
warning: user mockbuild does not exist - using root
<skip>
warning: group mockbuild does not exist - using root
Building target platforms: x86_64
Building for target x86_64
error: Failed build dependencies:
        audit-libs-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        binutils-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        bison is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        elfutils-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        flex is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        hmaccalc is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        newt-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        numactl-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        openssl-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        pciutils-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        perl(ExtUtils::Embed) is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        perl-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        perl-generators is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
        xz-devel is needed by kernel-4.15.0-0.rc2.git0.1.fc25.x86_64
Sleeping

P.S. I should be ashamed to call this junk a script.

DBabo 12-07-2017 05:43 PM

maybe you can try to install them?

me is an idiot.


All times are GMT -5. The time now is 02:16 AM.