[OE-core] [PATCH] rootfs_ipk.bbclass: Ensure bad recommendations persist in the status file

Andreas Oberritter obi at opendreambox.org
Tue Aug 26 00:51:16 UTC 2014


Hello Richard,

sorry for digging out such an old message, but please see below.

On 12.11.2011 09:36, Richard Purdie wrote:
> Currently bad recommendations are added to the status file with status
> "ok". After a single opkg command, whilst it will ignore the recommendation,
> the status changes to "installed" even if the recommended package was not
> installed. Whilst this is likely a glitch in opkg's logic, the correct
> way to persist the information in the status file is to set the status
> to "hold" as deinstall packages with that status remain. With this change
> the bad recommendations persist accross multiple opkg runs and the system
> behaves as expected.
> 
> [YOCTO #1758]
> 
> Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
> ---
> diff --git a/meta/classes/rootfs_ipk.bbclass b/meta/classes/rootfs_ipk.bbclass
> index 3b4c392..4a5a2dd 100644
> --- a/meta/classes/rootfs_ipk.bbclass
> +++ b/meta/classes/rootfs_ipk.bbclass
> @@ -44,7 +44,7 @@ fakeroot rootfs_ipk_do_rootfs () {
>  		pkginfo="`opkg-cl ${IPKG_ARGS} info $i`"
>  		if [ ! -z "$pkginfo" ]; then
>  			echo "$pkginfo" | grep -e '^Package:' -e '^Architecture:' -e '^Version:' >> $STATUS
> -			echo "Status: deinstall ok not-installed" >> $STATUS
> +			echo "Status: deinstall hold not-installed" >> $STATUS

I just implemented bad recommendations for deb (in dora) and by looking
at dpkg's source code I realized that "hold" is only a valid value for
the first field. Maybe you meant to write "Status: hold ok
not-installed" instead? Valid values for the second field are ok and
reinstreq.

The code above doesn't exist in master anymore, but the status line
hasn't changed in the newer version implemented in python.

Regards,
Andreas



More information about the Openembedded-core mailing list