Bug 2741

Summary: PN -> PACKAGES mappings for each available recipe
Product: [Build System, Metadata & Runtime] BitBake Reporter: Robert Yang <liezhi.yang>
Component: bitbakeAssignee: Robert Yang <liezhi.yang>
Status: VERIFIED FIXED QA Contact:
Severity: enhancement    
Priority: Medium CC: bluelightning, jason.wessel, jeff.polk, liang.li2, mark.hatle, poky.bs.watcher, poky.watcher, richard.purdie, sgw, song.liu, zhenfeng.zhao
Version: 1.3   
Target Milestone: 1.3 M3   
Hardware: x86   
OS: Multiple   
Whiteboard: (P2)(QA Testing Completed)(Done)
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: ---

Description Robert Yang 2012-07-12 02:42:31 UTC
The ability to know PN -> PACKAGES mappings for each available recipe.

The data are stored in bb_cache.dat, here are the draft thoughts for it:

1) The filename might be pn_mapping

2) Save the pn_mapping whenever the recipes have been parsed (just like bb_cache.dat).

3) The format could be:
   PN: pkg1 pkg2 pkg3 ... (include -dev, -dbg and -doc pkgs?)

4) I think that we only need the target recipe's mapping, don't need the -native or -nativesdk ones, since they won't generate out binary PACKAGES.
Comment 1 Robert Yang 2012-08-03 08:20:06 UTC
Added a script bitbake/contrib/dump_cache.py to dump the bb_cache.dat, and merged into master:

http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=9461854a3cf64a1d8fbf0248140d91bbd0a8e054
Comment 2 liang li 2012-08-09 03:09:02 UTC
verified on :
git info:87ffccb5dc184375e8807834e3b9b08ada708105
git branch:poky/master

test env
host: ubuntu 12.04 x86_64

1. run "bitbake core-image-sato" to build qemux86 sato image.
2. run "./dump_cache.py path_to_builddir/tmp/cache/default-eglibc/qemux86/bb_cache.dat.94c724cb01c96bedece06ebe6b57a054  | grep bzip2" ,output below:
path_to_git/meta/recipes-extended/bzip2/bzip2_1.0.6.bb bzip2 1.0.6 libbz2 libbz2-dev libbz2-staticdev bzip2-dbg bzip2-staticdev bzip2-dev bzip2-doc bzip2-locale bzip2 

also can get other bb's related info similar to the info of bzip2_1.0.6.bb.