LTIB - Steps to build custom kernel

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LTIB - Steps to build custom kernel

2,500 Views
dmarks_ls
Senior Contributor I

I'm taking a crack at building a custom kernel within LTIB 2010-09-19 for M54455EVB, because I'm going to need support for Wi-Fi cards that aren't supported (or stable) in 2.6.29.

 

So, I pulled down a kernel source archive and unzipped it, then went into LTIB and specified "Local Linux directory build", pointing to the kernel source directory.  I also enabled the option to build out of tree and specified a separate directory for that.  I also specified the option to Configure the kernel (duh), then exited LTIB's menuconfig.  At that point, LTIB proceeded to start a build (probably leading up to doing the kernel's menuconfig), but bombed out immediately, complaining that "PKG_KERNEL_PRECONFIG: must be set to the name of your .config file".  I looked in main.lkc and saw the block where PKG_KERNEL_PRECONFIG was being set based on kernel and platform selection, so I cloned one of the config files and added in this line to main.lkc:

 

    default "linux-custom-m54455evb.config" if KERNEL_DIR_BUILD && PLATFORM = "m54455evb"

That seemed to satisfy LTIB and allowed me to run the kernel menuconfig (and it was the menuconfig belonging to the new kernel source).  After exiting that, it began the kernel build but almost immediately failed, with the error "No rule to make target `uImage'.  Stop."  I tried again, specifying not to build out of tree, but got the same error.

 

Has anyone had any success building a newer kernel via LTIB?  Any basic steps or techniques I need to use?  Thanks.

Labels (1)
0 Kudos
Reply
2 Replies

631 Views
maxhexis
Contributor I

Hi,

 

I don't think using a custom kernel is really an easy way, as ltib includes lot of kernel specific patches, not included in the mainstream kernel.

If you just have to include different drivers, the best path could be to backport the drivers in the ltib specific kernel.

You can just work on the expanded kernel tree, checking the 'leave sources...' flag in the build configuration, and includeing the missing driver under rpm/BUILD/linux/kernel/drivers.

When you are satisfied, you can then ask ltib to automatically create a new patch for your driver.

 

Best regards,

 

        Max

0 Kudos
Reply

631 Views
dmarks_ls
Senior Contributor I

Yeah, we've decided to go the backporting route.  We need to support late-model Wi-Fi cards like atk9k, but because Freescale doesn't bother to submit their patches to Linus, we'd have to re-patch a new kernel with the 96 patches that are currently included in the M54455EVB BSP.  So we're using 2.6.29 with compat_wireless to shoehorn the new drivers into the old kernel.

0 Kudos
Reply