<?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>10298</bug_id>
          
          <creation_ts>2016-09-17 04:46:01 +0000</creation_ts>
          <short_desc>Suggested DEPENDS update to demystify the implementation and give more examples</short_desc>
          <delta_ts>2016-09-26 16:05:11 +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>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard>26 Sept 2016: RESOLVED</status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</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>srifenbark</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>Done (doc changes complete)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>66281</commentid>
    <comment_count>0</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-17 04:46:01 +0000</bug_when>
    <thetext>Hello,

Here&apos;s a suggested update to the DEPENDS glossary entry that tries to demystify
the implementation, makes the description similar in structure to the RDEPENDS
glossary entry, and adds another example. It replaces everything before the
notes.

  Lists a recipe&apos;s build-time dependencies. These are other recipes whose
  contents (e.g. headers and shared libraries) are needed by the recipe at
  build time.
  
  As an example, consider a recipe foo that contains the following assignment:
  
    DEPENDS = &quot;bar&quot;
  
  The practical effect of the above assignment is that all files installed by
  bar will be available in the appropriate staging sysroot (see the
  [STAGING_DIR*](http://www.yoctoproject.org/docs/latest/ref-manual/ref-manual.html#var-STAGING_DIR)
  variables) by the
  time foo&apos;s [do_configure] task runs. This is implemented by having
  do_configure depend on the [do_populate_sysroot] task of each recipe listed
  in DEPENDS (through a
  [[deptask]](https://www.yoctoproject.org/docs/2.2/bitbake-user-manual/bitbake-user-manual.html#variable-flags)
  declaration in [base.bbclass]).
  
  Note that it seldom is necessary to reference e.g. STAGING_DIR_HOST
  explicitly. The standard classes and build-related variables are configured
  to automatically use the appropriate staging sysroots.

  As another example, DEPENDS can also be used to add utilities that run on the
  build machine during the build. For example, a recipe that makes use of a
  code generator built by the recipe &apos;codegen&apos; might have the following:

    DEPENDS = &quot;codegen-native&quot;

  See [native.bbclass] and [EXTRANATIVEPATH].


Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66503</commentid>
    <comment_count>1</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-22 16:09:36 +0000</bug_when>
    <thetext>Hi Ulf, 

See http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-DEPENDS for the updates. 

Thanks, 
Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66509</commentid>
    <comment_count>2</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-22 16:52:25 +0000</bug_when>
    <thetext>Hello,

* I think the second sentence would be a bit easier to understand (especially
  to many non-native speakers) without the &quot;on&quot;:

    These are other recipes whose contents (e.g. headers and shared libraries)
    are needed by the recipe at build time.

* &quot;(i.e. STAGING_DIR* variables)&quot; ought to be &quot;(i.e. STAGING_DIR* variable)&quot; (singular)

* Maybe a comma before &quot;through a [deptask] declaration in the base class&quot; would give some breathing room. :)

Thanks,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66512</commentid>
    <comment_count>3</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-22 17:26:05 +0000</bug_when>
    <thetext>Hmm... I guess plural works too for

  (i.e. STAGING_DIR* variables)

, since some of the variables could be the same. It seems a bit cryptic though. 

How about the following?

  (given by the STAGING_DIR* variables)

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66532</commentid>
    <comment_count>4</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-22 23:17:33 +0000</bug_when>
    <thetext>Ulf, 

I am assuming this is what you were suggesting (http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-DEPENDS).  I took it out of the () construct and let it flow with the sentence. 

Thanks, 
Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66540</commentid>
    <comment_count>5</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-23 09:02:26 +0000</bug_when>
    <thetext>(In reply to comment #4)
&gt; Ulf, 
&gt; 
&gt; I am assuming this is what you were suggesting
&gt; (http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-
&gt; DEPENDS).  I took it out of the () construct and let it flow with the
&gt; sentence. 
&gt; 
&gt; Thanks, 
&gt; Scott

Looks good.


How about writing

  Lists a recipe&apos;s build-time dependencies. These are dependencies on other
  recipes whose...

instead of

  Lists a recipe&apos;s build-time dependencies. These dependencies are on other
  recipes whose... 

?

For some reason the first version makes my brain think there&apos;s an extra indirection there when I read it quickly.


Maybe a comma could be added to

 This mechanism is implemented by having do_configure depend on the
 do_populate_sysroot task of each recipe listed in DEPENDS through a
 [deptask]declaration in the base class.

as well, making it

 This mechanism is implemented by having do_configure depend on the
 do_populate_sysroot task of each recipe listed in DEPENDS, through a
 [deptask]declaration in the base class.


Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66556</commentid>
    <comment_count>6</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-23 16:01:41 +0000</bug_when>
    <thetext>Ulf, 

That is cool.. changes in.  See http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-DEPENDS.

Thanks, 
Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66559</commentid>
    <comment_count>7</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-23 16:55:43 +0000</bug_when>
    <thetext>(In reply to comment #6)
&gt; Ulf, 
&gt; 
&gt; That is cool.. changes in.  See
&gt; http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-DEPENDS.
&gt; 
&gt; Thanks, 
&gt; Scott

I&apos;m fine with it now. ty!

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66561</commentid>
    <comment_count>8</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-23 18:27:54 +0000</bug_when>
    <thetext>Thanks, 

Setting to RESOLVED and putting the doc flag to &quot;done.&quot;

Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66562</commentid>
    <comment_count>9</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-09-23 18:49:40 +0000</bug_when>
    <thetext>Sorry... saw one more small nit. Could close right away afterwards whether you
agree or not. I&apos;m a bit extra OCD when it comes to variables that are likely
to be looked up a ton. :)

I&apos;d add two more commas and rephrase slightly, to turn 

  The practical effect of the previous assignment is that all files installed
  by bar will be available in the appropriate staging sysroot given by the
  STAGING_DIR* variables by the time the do_configure task for foo runs.

into

  The practical effect of the previous assignment is that all files installed
  by bar will be available in the appropriate staging sysroot, given by the
  STAGING_DIR* variables, by the time foo&apos;s do_configure task runs.

Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66586</commentid>
    <comment_count>10</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-09-26 16:05:11 +0000</bug_when>
    <thetext>Ok - Changed it.  Left the last structure as was so I could avoid &quot;foo&apos;s&quot; since I format &quot;foo&quot;.  See http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#var-DEPENDS

Setting to RESOLVED again.

Scott</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>