rebuilding the kernel?

Started by flipflops, March 14, 2013, 04:43:36 AM

Previous topic - Next topic

flipflops

I am trying to rebuild my running kernel but every reference to kernel building is on x86 systems with a boot loader like grub, lilo, ramdisk, etc and this does not work on the olimex that uses u-boot as the boot loader so I am looking for some help recompiling my running kernel with new options set with make menuconfig.

I found the kernel sources as an arch pkgbuild at:

https://github.com/archlinuxarm/PKGBUILDs/tree/master/core/linux-olinuxino

and I have run makepkg on it, stopping before make runs in PKGBUILD so I can change config options later before compiling. I dont want to compile it as a package and install it with pacman because this is right for x86 with grub but does not sound right for embedded with u-boot.

All I want to do is reconfigure the running kernel and recompile it. Surely I dont need to rebuild the entire system to do this. I have tried to reconfigure/compile from /usr/src but there are Kconfig files where make wants to see Makefiles so I cant rebuild from /usr/src

Anybody know how to rebuild the running kernel on the olimex maxi?



jeroends

Look at: https://github.com/koliqi/imx23-olinuxino . This is very nicely explained how to compile your kernel. Those links and explanations can be found in the wiki, please read them.

Bert

is it possible to install new kernel without destroying SDcard? I mean all this tutorials expects "clean install" but not upgrading

flipflops

There are several oilinuxino specific arch packages available that you can see with:

pacman -Ss olinuxino

There are kernel26 and kernel37 headers, kernels, and kernel modules available to be installed as arch packages with pacman -Sy
but there are two problems:

How can you reconfigure/compile a kernel as an installed package?
How can you configure u-boot to boot to the kernel as an installed package?

ArOne

I'd like to ask a related question.

I've followed this guide https://github.com/koliqi/imx23-olinuxino but it doesn't explain how to make or find a rootfs that works with it.  If this is some kind of common knoweledge in linux world then I am ignorant of it.  Are there any premade rootfs that work with the kernel made from this guide or is there a guide on how to use multistrap/debstrap and make a rootfs just for this kernel?

jeroends

You can simply use put your kernel on the sd card using for ex the debian rootfs. The only thing you may not forget is to install the modules that are compiled with that kernel. After that everything should be fine.

flipflops

Yes, the referenced howto does not cover the kernel modules installation.