How To Install A Higher Version of the Kernel, Build/Compile and Make the System Used It

I went the exercise of trying optimize all the drivers once, it took a very long time.

While it has been a long time (almost a plural, decades) since I've tinkered with optimizing a kernel for my own hardware, the sauce has not been worth the squeeze on modern hardware for a long time.

Now, I might modify something I compile to use all the cores I have available...
 


ohh, I don't think that you dis Slackware :)
I think though that if anything in regards of kernel custom installation I think that Slackware is the easiest just need kernel sources. But everything is relative so whatever is most convenient for the user is the best.
Agreed, the 2 videos that I watched on how to install and compile a kernel for Slackware does seems a lot easier.
 
Still not feeling like myself however; this is in progress, waiting for the update in Debian 12 to finish in Virtual Box.
There were 404 packages to be updated/upgraded and I've been waiting over an hour for this to complete.

Can't really do anything until this finishes.
 

Attachments

  • Deb12 UpdateVB.png
    Deb12 UpdateVB.png
    159.5 KB · Views: 20
Managed to get Kernel 6.12.10 downloaded.
It's after 5 and the day is shot.

I'll follow the instructions in the morning and get the ball rolling.
 

Attachments

  • Kernel 6.12.10.png
    Kernel 6.12.10.png
    195.5 KB · Views: 26
Having issues trying to install libqwt-qt6-dev. Apt evidentially can't find it.

The only pkg of libqwt that I could find is experimental.

I haven't copied the current kernel config yet because I'still need the aboove pkg and I'm not so sure if using the libqwt experimental is wise.
What do you think @dos2unix?
 

Attachments

  • libqwt Unable.png
    libqwt Unable.png
    298 KB · Views: 27
  • libqwt Exp.png
    libqwt Exp.png
    238.4 KB · Views: 20
I haven't copied the current kernel config yet because I'still need the aboove pkg and I'm not so sure if using the libqwt experimental is wise.

Are you using menuconfig or xconfig? I would think you wouldn't need it at all if using menuconfig.
Do you get an error? Is it possible your system uses qt5?
 
Last edited:
Are you using menuconfig or xconfig? I would think you wouldn't need it at all if using menuconfig.
Do you get an error? Is it possible your system uses qt5?
I'm using menuconfig.
I had an error after untarring the kernel. I checked after the unpacking finished. The files for the new kernel are all there is the Downloads directory.
Code:
exiting with failure status due to previous errors

Looking at the path: /usr/lib/x86_64-linux-gnu/ there is a qt5 directory that has 3 sub-directories...libexec, plugins and qml. It looks like this Debian 12 Mate system uses qt5.
 
This is a guess, but instead of...libqwt-qt6-dev, maybe try libqwt-qt5-dev ?

Also make sure you run a "make clean" before trying again.
Always do a "make clean" after every try.
 
Last edited:
This is a guess, but instead of...libqwt-qt6-dev, maybe try libqwt-qt5-dev ?

Also make sure you run a "make clean" before trying again.
Always do a "make clean" after every try.
After shutting down the vm and trying again APT found qt5- YAY!
Thanks for the reminder to make clean each time.
 

Attachments

  • QT%.png
    QT%.png
    283.4 KB · Views: 24
Coping the current kernel config went well. Make menuconfig failed with errors.

Code:
bin/sh: 1: flex: not found
make[2]: *** [scripts/Makefile.host:9: scripts/kconfig/lexer.lex.c] Error 127
make[1]: *** [/home/alex/Downloads/linux-6.12.10/Makefile:680: menuconfig] Error 2
make: *** [Makefile:224: __sub-make] Error 2

Greek to me brother-
 
You need flex installed.
It's usually a pretty small package.

Edit: Update:
I installed Debian 12.9 on a VM, and I'm going through this right now.

I also had to install
flex
bison
libelf-dev
libssl-dev
libqwt-qt5-dev

It is finally compiling; this may take a while.

I grabbed lucky 6.13 :)
 
Last edited:
OK. It's done Debian 12.9
Note: I ran all of this as root, just to make life easier.
I had to disable secure boot. (I'm pretty sure there is a way to sign the boot shim, but
I didn't try that yet).

Code:
cd /home/ray
wget https://cdn.kernel.org/oub/linux/kernel/v6.x/linux-6.13.tar.xz
tar -xvJf linux-6.13.tar.xz
apt-get update && apt-get upgrade
apt-get install build-essential flex bison
apt-get install libncurses-dev libqwt-qt5-dev libelf-dev libssl-dev
cd linux-6.13/
make clean
cp /boot/config-$(uname -r) .config
cp /boot/config-$(uname -r) .config.backup
make menuconfig
make -j$(nproc)
make modules
make modules_install
make install
update-initramfs -c -k 6.13.0
grub-mkconfig -o /boot/grub/grub.cfg
sync; reboot
 
You need flex installed.
It's usually a pretty small package.

Edit: Update:
I installed Debian 12.9 on a VM, and I'm going through this right now.

I also had to install
flex
bison
libelf-dev
libssl-dev
libqwt-qt5-dev

It is finally compiling; this may take a while.

I grabbed lucky 6.13 :)
I'm running the same.
Code:
debian-box:~$ cat /etc/debian_version
12.9

When I have time I'll install those pkg's you listed. Thanks!
Be back later.
 
Making progress today.
Code:
Unpacking flex (2.6.4-8.2) ...
Selecting previously unselected package bison.
Preparing to unpack .../bison_2%3a3.8.2+dfsg-1+b1_amd64.deb ...
Unpacking bison (2:3.8.2+dfsg-1+b1) ...
Selecting previously unselected package libfl2:amd64.
Preparing to unpack .../libfl2_2.6.4-8.2_amd64.deb ...
Unpacking libfl2:amd64 (2.6.4-8.2) ...
Selecting previously unselected package libfl-dev:amd64.
Preparing to unpack .../libfl-dev_2.6.4-8.2_amd64.deb ...
Unpacking libfl-dev:amd64 (2.6.4-8.2) ...
Setting up m4 (1.4.19-3) ...
Setting up libfl2:amd64 (2.6.4-8.2) ...
Setting up bison (2:3.8.2+dfsg-1+b1) ...
 
Kernel Config came up. Never been here before so I'll go slow.
Still running after executing make -j......
 

Attachments

  • Kernel Config.png
    Kernel Config.png
    194.9 KB · Views: 15
  • Make j.png
    Make j.png
    228.2 KB · Views: 13
Last edited:
Started at 10:51 a.m. and finished at 12:46 p.m.

Error as there isn't enough space on the vm and some make errors as well.
I'm not sure if there is a way to resize the vm I have already created for this Debian 12 install in vm.
I'll have to check and do some reading.

Code:
/tmp/cczdPCSB.s: Fatal error: can't write 76 bytes to section .init.text of drivers/net/wireless/intel/ipw2x00/ipw2200.o: 'No space left on device'
/tmp/cczdPCSB.s: Fatal error: drivers/net/wireless/intel/ipw2x00/ipw2200.o: No such file or directory
make[7]: *** [scripts/Makefile.build:229: drivers/net/wireless/intel/ipw2x00/ipw2200.o] Error 1
make[6]: *** [scripts/Makefile.build:478: drivers/net/wireless/intel/ipw2x00] Error 2
make[5]: *** [scripts/Makefile.build:478: drivers/net/wireless/intel] Error 2
make[4]: *** [scripts/Makefile.build:478: drivers/net/wireless] Error 2
make[3]: *** [scripts/Makefile.build:478: drivers/net] Error 2
make[2]: *** [scripts/Makefile.build:478: drivers] Error 2
make[1]: *** [/home/alex/Downloads/linux-6.12.10/Makefile:1937: .] Error 2
make: *** [Makefile:224: __sub-make] Error 2

Proceeded with make modules and it's running. So far so good.
 
Last edited:
Code:
error: can't write 76 bytes to section .init.text of drivers/net/wireless/intel/ipw2x00/ipw2200.o: 'No space left on device'

No space left of device, says your hard drive is full.

What is output of

Code:
df -h
 
Code:
alex@debian:~$ df -h
Filesystem      Size  Used Avail Use% Mounted on
udev            939M     0  939M   0% /dev
tmpfs           197M 1008K  196M   1% /run
/dev/sda1        19G   12G  6.0G  67% /
tmpfs           984M     0  984M   0% /dev/shm
tmpfs           5.0M  8.0K  5.0M   1% /run/lock
tmpfs           197M   60K  197M   1% /run/user/1000
 
interesting

Code:
/dev/sda1        19G   12G  6.0G  67% /

I don't see anything full, but I will say, 20G is a pretty small drive for a system you will be compiling a kernel on.
But still, it seems to be saying you have 6G available. Maybe it's checking to see if you have enough space to install
the modules before it actually writes them to disk? But remember, after the modules are installed, you still have to "make install" the kernel itself. That will take up even more space.
 

Members online


Top