[bitbake-devel] [PATCH 1/1] bitbake: add description cache into cache_extra

Richard Purdie richard.purdie at linuxfoundation.org
Fri Jan 27 16:35:28 UTC 2012


On Fri, 2012-01-20 at 19:39 +0800, Shane Wang wrote:
> enable bitbake to cache description into the extra cache file and Hob2 will get its value for core-image-foo.
> 
> Signed-off-by: Shane Wang <shane.wang at intel.com>
> ---
>  bitbake/lib/bb/cache_extra.py |   13 +++----------
>  bitbake/lib/bb/cooker.py      |    2 ++
>  2 files changed, 5 insertions(+), 10 deletions(-)
> 
> diff --git a/bitbake/lib/bb/cache_extra.py b/bitbake/lib/bb/cache_extra.py
> index 4c8841f..723b97f 100644
> --- a/bitbake/lib/bb/cache_extra.py
> +++ b/bitbake/lib/bb/cache_extra.py
> @@ -36,19 +36,12 @@ class HobRecipeInfo(RecipeInfoCommon):
>      cachefile = "bb_extracache_" + classname +".dat"        
>  
>      def __init__(self, filename, metadata):
> -
> -        self.summary = self.getvar('SUMMARY', metadata)
> -        self.license = self.getvar('LICENSE', metadata)
> -        self.section = self.getvar('SECTION', metadata)
> +        self.description = self.getvar('DESCRIPTION', metadata)
>  
>      @classmethod
>      def init_cacheData(cls, cachedata):
>          # CacheData in Hob RecipeInfo Class
> -        cachedata.summary = {}
> -        cachedata.license = {}
> -        cachedata.section = {}
> +        cachedata.description = {}
>  
>      def add_cacheData(self, cachedata, fn):
> -        cachedata.summary[fn] = self.summary
> -        cachedata.license[fn] = self.license
> -        cachedata.section[fn] = self.section
> +        cachedata.description[fn] = self.description

I think rather than remove the summary/license/section fromhere, we
should remove them from the main cache. There were added there as a
temporary measure before we had multiple cache support and we should
remove them now since they're only used by the hob UI, just like
description.

Cheers,

Richard





More information about the bitbake-devel mailing list