<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>10066</bug_id>
          
          <creation_ts>2016-08-02 20:04:14 +0000</creation_ts>
          <short_desc>Suggested new section on listing package contents</short_desc>
          <delta_ts>2016-09-07 21:02:53 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>9</classification_id>
          <classification>Documentation</classification>
          <product>Reference</product>
          <component>handbook</component>
          <version>2.2</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>MOVED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard>07 Sept 2016: RESOLVED/MOVED</status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>2.2 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>ulfalizer</reporter>
          <assigned_to name="Scott Rifenbark">srifenbark</assigned_to>
          <cc>bluelightning</cc>
    
    <cc>poky.doc.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>sgw</cc>
    
    <cc>srifenbark</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>64795</commentid>
    <comment_count>0</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-08-02 20:04:14 +0000</bug_when>
    <thetext>Could we add the following section to the reference manual? I&apos;ve seen many people wonder how to list package contents.

The oe-pkgdata-util utility is currently undocumented, and the bb utility very hard to discover, so getting some coverage for those is nice too.

  2.3.4. Listing package contents
  
  Listing the files inside a package can be a useful debugging aid. Below are a
  few different ways to do it.
  
    1. Build the recipe that generates the package and then run the following
       command:
  
         $ oe-pkgdata-util list-pkg-files &lt;package&gt;
  
       If you are unsure what the name of the package is, the following command
       will list all packages for which package information is available:
  
         $ oe-pkgdata-util list-pkgs
  
       You can also search for packages using wildcards. For example, the
       following command lists all package names starting with &quot;foo&quot;:
  
         $ oe-pkgdata-util list-pkgs &quot;foo*&quot;
  
       oe-pkgdata-util lives in the scripts/ directory under the
       [Source Directory].
  
    2. Install the &apos;bb&apos; utility from https://github.com/kergoth/bb. This utility
       has a &apos;contents&apos; subcommand that can be used to list the contents of all
       packages generated by a given recipe. Like with oe-pkgdata-util, the
       recipe must be built before package contents can be listed. Also make sure
       that you do not have
       [rm_work](http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#ref-classes-rm-work)
       enabled, as this will remove needed information.
  
    3. List the contents of the ${WORKDIR}/packages-split directory for the
       recipe that generates the package. This directory has one subdirectory per
       package generated by the recipe, containing the files stored in that
       package. Make sure that you have built the recipe first and are not
       running with rm_work enabled.
  
    4. Finally, it is always possible to directly inspect the generated packages
       in ${DEPLOY_DIR_IPK}, ${DEPLOYR_DIR_RPM}, etc. How this is done depends on
       the packaging format.


Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64803</commentid>
    <comment_count>1</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2016-08-02 20:34:52 +0000</bug_when>
    <thetext>&apos;bb&apos; isn&apos;t part of official releases, thus I don&apos;t think it should be part of the manual. If we had no alternative for this use case that was part of the official release there would be a good case to document it, but that&apos;s not true here.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64805</commentid>
    <comment_count>2</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-08-02 20:40:45 +0000</bug_when>
    <thetext>Set up some parameters so the bug is not flagged later for me as missing target and time.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64806</commentid>
    <comment_count>3</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-08-02 20:45:01 +0000</bug_when>
    <thetext>(In reply to comment #1)
&gt; &apos;bb&apos; isn&apos;t part of official releases, thus I don&apos;t think it should be part
&gt; of the manual. If we had no alternative for this use case that was part of
&gt; the official release there would be a good case to document it, but that&apos;s
&gt; not true here.

I think it&apos;s useful enough (in relation to manual spaminess :) to be worth mentioning, even if it&apos;s third-party. Removing that bullet isn&apos;t a huge deal though.

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64809</commentid>
    <comment_count>4</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2016-08-02 20:49:49 +0000</bug_when>
    <thetext>FWIW what I&apos;m concerned about with bb is that the user might try to use it and it doesn&apos;t work because something changed in the current release that broke it. For a concrete example, if my reworking of tinfoil goes in for this release it will definitely break bb. Chris may well fix it up immediately, but I don&apos;t know if that&apos;s guaranteed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64810</commentid>
    <comment_count>5</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-08-02 20:51:36 +0000</bug_when>
    <thetext>If this is documented, it would probably be better placed in the &quot;Working with Packages&quot; section in the development manual, which tries to be procedural, rather than the reference manual, which tries to be a reference.  We could reference the procedure section from within the debugging section of the reference manual.

Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64811</commentid>
    <comment_count>6</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-08-02 20:53:03 +0000</bug_when>
    <thetext>(In reply to comment #4)
&gt; FWIW what I&apos;m concerned about with bb is that the user might try to use it
&gt; and it doesn&apos;t work because something changed in the current release that
&gt; broke it. For a concrete example, if my reworking of tinfoil goes in for
&gt; this release it will definitely break bb. Chris may well fix it up
&gt; immediately, but I don&apos;t know if that&apos;s guaranteed.

I&apos;m fine with leaving it out in that case. If it&apos;s worthwhile, it could always be added later.

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64812</commentid>
    <comment_count>7</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-08-02 20:55:01 +0000</bug_when>
    <thetext>(In reply to comment #5)
&gt; If this is documented, it would probably be better placed in the &quot;Working
&gt; with Packages&quot; section in the development manual, which tries to be
&gt; procedural, rather than the reference manual, which tries to be a reference.
&gt; We could reference the procedure section from within the debugging section
&gt; of the reference manual.
&gt; 
&gt; Scott

I&apos;m fine with moving it. Placing it under Debugging Build Failures felt like a bit of a stretch to begin with.

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>64814</commentid>
    <comment_count>8</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-08-02 21:00:09 +0000</bug_when>
    <thetext>If it&apos;s moved, the opening sentence could be rewritten like this:

  While working on a recipe, it can be useful to see what files are in packages
  produced by the recipe. Below are a few different methods for listing the
  contents of a package.

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>65763</commentid>
    <comment_count>9</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-02 10:13:40 +0000</bug_when>
    <thetext>Hello,

Here&apos;s an updated version that removes the mention of &apos;bb&apos; and adds some information. I think it would fit pretty well under &apos;2.3. Debugging Tools and Techniques&apos; now, after it was renamed from &apos;2.3. Debugging Build Failures&apos;. There is already a bunch of sections on viewing different kinds of recipe- and package-related information, so this would just be another one.

Finally getting some documentation for oe-pkgdata-util would be nice too. :)

  2.3.4. Viewing package contents
  
  Listing the files inside a package can be a useful debugging aid. Below are a
  few different ways to do it.
  
    1. Build the recipe that generates the package and then run the following
       command:
  
         $ oe-pkgdata-util list-pkg-files &lt;package&gt;
  
       If you are unsure what the name of the package is, the following command
       will list all packages for which package information is available:
  
         $ oe-pkgdata-util list-pkgs
  
       You can also search for packages using wildcards. For example, the
       following command lists all package names starting with &quot;foo&quot;:
  
         $ oe-pkgdata-util list-pkgs &quot;foo*&quot;

       oe-pkgdata-util uses information from [PKGDATA_DIR].
  
    2. List the contents of the ${WORKDIR}/packages-split directory for the
       recipe that generates the package. This directory is created by the
       [do_package] task and has one subdirectory per package generated by the
       recipe, containing the files stored in that package. Make sure that you
       have built the recipe first and that you are not running with
       [rm_work](http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#ref-classes-rm-work)
       enabled.
  
    3. Finally, it is always possible to directly inspect the generated packages
       in ${DEPLOY_DIR_IPK}, ${DEPLOYR_DIR_RPM}, etc. How this is done depends on
       the packaging format.


Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>65764</commentid>
    <comment_count>10</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-02 10:22:01 +0000</bug_when>
    <thetext>Here&apos;s a slightly updated version. All packages that have been built should
have package information available, so the list-pkgs description was changed to
be more concrete.

  2.3.4. Viewing package contents
  
  Listing the files inside a package can be a useful debugging aid. A few
  different ways to do it are listed below:
  
    1. Build the recipe that generates the package and then run the following
       command:
  
         $ oe-pkgdata-util list-pkg-files &lt;package&gt;
  
       If you are unsure what the name of the package is, the following command
       will list all packages that have been built:
  
         $ oe-pkgdata-util list-pkgs
  
       You can also search for packages using wildcards. For example, the
       following command lists all package names starting with &quot;foo&quot;:
  
         $ oe-pkgdata-util list-pkgs &quot;foo*&quot;

       oe-pkgdata-util uses information from [PKGDATA_DIR].
  
    2. List the contents of the ${WORKDIR}/packages-split directory for the
       recipe that generates the package. This directory is created by the
       [do_package] task and has one subdirectory per package generated by the
       recipe, containing the files stored in that package. Make sure that you
       have built the recipe first and that you are not running with
       [rm_work](http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#ref-classes-rm-work)
       enabled.
  
    3. Finally, it is always possible to directly inspect the generated packages
       in ${DEPLOY_DIR_IPK}, ${DEPLOYR_DIR_RPM}, etc. How this is done depends on
       the packaging format.


Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>65786</commentid>
    <comment_count>11</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-03 15:17:14 +0000</bug_when>
    <thetext>Hello,

I thought about it some more, and I think it would be better to have a section about oe-pkgdata-util more generally. Here&apos;s a bug I filed for that: https://bugzilla.yoctoproject.org/show_bug.cgi?id=10216

That bug would replace this one completely.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>65890</commentid>
    <comment_count>12</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-07 21:01:03 +0000</bug_when>
    <thetext>Yes - I put the Bug 10216 out for review.  Check that. 

I am marking this as RESOLVED/MOVED since there is a new bug for it.

Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>65891</commentid>
    <comment_count>13</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-07 21:02:53 +0000</bug_when>
    <thetext>Forgot to reset the doc flag to &quot;No&quot;

Scott</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>