[yocto] Unable to upgrade kernel; package for kernel name includes version

Bryan Evenson bevenson at melinkcorp.com
Mon Nov 25 08:35:47 PST 2013


All,

> -----Original Message-----
> From: yocto-bounces at yoctoproject.org [mailto:yocto-
> bounces at yoctoproject.org] On Behalf Of Bryan Evenson
> Sent: Monday, November 25, 2013 9:46 AM
> To: yocto at yoctoproject.org
> Subject: [yocto] Unable to upgrade kernel; package for kernel name
> includes version
> 
> I'm on poky/dylan-9.0.1 I am upgrading the Linux kernel for my device's
> image from a custom 3.6.9 kernel to a custom 3.10 kernel.  I'm using
> this layer: https://github.com/evensonbryan/meta-atmel as a basis for
> the custom kernel recipe (there is a recipe for the 3.10 kernel that I
> haven't yet deployed to Github in case anyone is wondering).  I'm
> attempting to do a firmware upgrade with my built packages (using opkg
> for package management) and I've discovered an issue with the kernel
> naming.  On my pre-upgraded device, a list of installed packages
> includes:
> 
> kernel-devicetree
> kernel-image-3.6.9-yocto-standard
> 
> So when I build my updated Linux kernel, the kernel image is now named
> "kernel-image-3.10.0-yocto-standard".  So when I attempt to do an
> upgrade, the kernel-devicetree is upgraded just fine but the kernel
> image is not; kernel-image-3.10.0-yocto-standard is not the same
> package as kernel-image-3.6.9-yocto-standard, so opkg does not see this
> as an upgrade.
> 
> How do I force the packaging system to recognize that the new kernel is
> an upgrade of the old kernel, even though the packages have different
> names?  And for the future, how do I change the package name so that it
> doesn't include the version?

I have a partial solution, but I'm still curious as to if there is a cleaner method than what I've found so far.  I have a package that is an image version so that way I can easily tell the overall distribution version.  In that package, I added the line:

RDEPENDS_${PN} = "kernel-image (>= 3.10)"

When I did this, upgrading my image version package caused kernel-image-3.10.0-yocto-standard to be installed.  However, opkg still claims that kernel-image-3.6.9-yocto-standard is still installed; it'd be nice to remove this package also.  Would adding:

RCONFLICTS_${PN} = "kernel-image-3.6.9-yocto-standard"
RREPLACES_${PN} = "kernel-image-3.6.9-yocto-standard"

to the 3.10 kernel recipe fix the issue?  And if so, moving forward would I then need to append the list with each kernel version that is created, in case I have an old system that has never been upgraded?  I think this will work, but it seems messy.

Thanks,
Bryan
> 
> Thanks,
> Bryan
> 
> 
> 
> _______________________________________________
> yocto mailing list
> yocto at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto



More information about the yocto mailing list