<?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>10392</bug_id>
          
          <creation_ts>2016-10-07 05:19:52 +0000</creation_ts>
          <short_desc>Some suggested changes in &apos;5.3.20.5. Packaging Externally Produced Binaries&apos;</short_desc>
          <delta_ts>2016-10-11 14:38:53 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>9</classification_id>
          <classification>Documentation</classification>
          <product>Development Manual</product>
          <component>development</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>11 Oct 2016: RESOLVED</status_whiteboard>
          <keywords></keywords>
          <priority>Undecided</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.3 M1</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>ulfalizer</reporter>
          <assigned_to name="Scott Rifenbark">srifenbark</assigned_to>
          <cc>bluelightning</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>67029</commentid>
    <comment_count>0</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-10-07 05:19:52 +0000</bug_when>
    <thetext>Hello Scott,

Here&apos;s two suggested changes in &apos;5.3.20.5. Packaging Externally Produced Binaries&apos;

1. I often see people needlessly putting [noexec] on tasks, making recipes more
   complicated than they need to be. Replacing the first note with the
   following one might help. I think the note about making the tasks empty at
   the end could be removed, because [noexec] is simpler.

     * Create a recipe where the do_configure and do_compile tasks do nothing.
       It is usually sufficient to just not define these tasks in the recipe,
       because the default implementations do nothing unless a Makefile is
       found in ${S}.
       
       If ${S} might contain a Makefile, or if you inherit some class that
       replaces do_configure and do_compile with custom versions, then you can
       use the [[noexec]](https://www.yoctoproject.org/docs/2.2/bitbake-user-manual/bitbake-user-manual.html#variable-flags)
       flag to turn the tasks into no-ops, as follows:

         do_configure[noexec] = &quot;1&quot;
         do_compile[noexec] = &quot;1&quot;

       Unlike [deleting the tasks](https://www.yoctoproject.org/docs/2.2/bitbake-user-manual/bitbake-user-manual.html#deleting-a-task),
       this preserves the dependency chain from the do_fetch, do_unpack, and
       do_patch tasks to the do_install task.

2. There&apos;s already a note in the DEPENDS glossary entry, but I think it helps
   to emphasize that DEPENDS might be needed for binary components here as
   well. This new note could be added at the end:

     * Using [DEPENDS] is a good idea even for components distributed in binary
       form, and often necessary for shared libraries. For a shared library,
       listing the library dependencies in DEPENDS makes sure that they are
       available in the staging sysroot when other recipes link against the
       library, which might be necessary for successful linking.
       
       Using DEPENDS also allows runtime dependencies between packages to be
       added automatically. See the
       [Automatically Added Runtime Dependencies](http://www.yoctoproject.org/docs/2.2/ref-manual/ref-manual.html#automatically-added-runtime-dependencies)
       section in the Yocto Project Reference Manual.


Cheers,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>67097</commentid>
    <comment_count>1</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-10-10 18:23:25 +0000</bug_when>
    <thetext>Hi Ulf, 

See http://www.yoctoproject.org/docs/2.2/dev-manual/dev-manual.html#packaging-externally-produced-binaries for the first change.  I am unclear what you want me to do for where you say &quot;I think the note about making the tasks empty at the end could be removed, because [noexec] is simpler.&quot;  I don&apos;t see that in the original section.  So maybe you can explain that further to me.

See the newly added last bullet item for the second change about mentioning DEPENDS.  

Thanks,
Scott</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>67115</commentid>
    <comment_count>2</comment_count>
    <who name="">ulfalizer</who>
    <bug_when>2016-10-11 00:59:05 +0000</bug_when>
    <thetext>Hello,

The old description had &quot;alternatively, you can make these tasks an empty function&quot;, so that was what I was talking about. :)

The changes look good. I just realized that it&apos;s a bit weird to have the DEPENDS bullet item at the end though, since it applies regardless of whether you&apos;re using bin_package. Could it be turned into a Note {} and moved before &quot;if you can&apos;t use the bin_package class, you need...&quot; instead?

Could close right away after that.

Thanks,
Ulf</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>67138</commentid>
    <comment_count>3</comment_count>
    <who name="Scott Rifenbark">srifenbark</who>
    <bug_when>2016-10-11 14:38:53 +0000</bug_when>
    <thetext>Ulf, 

Ok - fixed it up.  See http://www.yoctoproject.org/docs/2.2/dev-manual/dev-manual.html#packaging-externally-produced-binaries.

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

Thanks, 
Scott</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>