<?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>9784</bug_id>
          
          <creation_ts>2016-06-16 12:54:56 +0000</creation_ts>
          <short_desc>Building with -c rootfs fails if toaster and buildhistory are inherited</short_desc>
          <delta_ts>2016-08-12 20:00:16 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>core</component>
          <version>2.1</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.2 M2</target_milestone>
          <dependson>8556</dependson>
          <blocked>9856</blocked>
    
    <blocked>9893</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Peter Kjellerstedt">peter.kjellerstedt</reporter>
          <assigned_to name="Elliot Smith">elliot.smith</assigned_to>
          <cc>jose.perez.carranza</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
          
          <qa_contact name="Jose Perez C">jose.perez.carranza</qa_contact>
          <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>63021</commentid>
    <comment_count>0</comment_count>
    <who name="Peter Kjellerstedt">peter.kjellerstedt</who>
    <bug_when>2016-06-16 12:54:56 +0000</bug_when>
    <thetext>If one inherits toaster and buildhistory and the build an image with -c rootfs (without having built an image before), the build fails. This is because the code in toaster.bbclass assumes that buildhistory/images/${MACHINE_ARCH}/${TCLIBC}/&lt;target&gt; (if it exists) contains a files-in-image.txt file. This, however, is not true until an image has been created, but the directory exists already after rootfs has been created.

Another consequence of this is that if one first builds an image, then do some changes, and then build only the rootfs, toaster.bbclass will still find the old files-in-image.txt file from the previous image...

Steps to reproduce:
* git clone http://git.yoctoproject.org/git/poky poky
* cd poky
* . ./oe-init-build-env
* echo &apos;INHERIT += &quot;buildhistory toaster&quot;&apos; &gt;&gt;conf/local.conf
* echo &apos;BUILDHISTORY_COMMIT = &quot;1&quot;&apos; &gt;&gt;conf/local.conf
* bitbake core-image-minimal -c rootfs</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>63240</commentid>
    <comment_count>1</comment_count>
    <who name="Elliot Smith">elliot.smith</who>
    <bug_when>2016-06-22 08:13:54 +0000</bug_when>
    <thetext>After discussion, the solution may be to link creation of files-in-image.txt to do_rootfs. This should ensure that the file is updated whenever rootfs runs (which is when the list of files in files-in-image.txt changes).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>63495</commentid>
    <comment_count>2</comment_count>
    <who name="Elliot Smith">elliot.smith</who>
    <bug_when>2016-06-30 11:10:54 +0000</bug_when>
    <thetext>Depends on bug 8556, as that reworks toaster.bbclass and buildinfohelper significantly. Any work done here will clash with those changes, so wait until fixes for bug 8556 are in before approaching this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>63967</commentid>
    <comment_count>3</comment_count>
    <who name="Elliot Smith">elliot.smith</who>
    <bug_when>2016-07-14 09:06:34 +0000</bug_when>
    <thetext>Submitted as part of the patchset for 8556:
https://lists.yoctoproject.org/pipermail/toaster/2016-June/004899.html

The commit which is relevant here is:
http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=elliot/toaster/8556-image_fstypes&amp;id=2db715753e81eb5a25e30a040ade190b383b7c79

Brian is currently in the process of upstreaming this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>65146</commentid>
    <comment_count>4</comment_count>
    <who name="Jose Perez C">jose.perez.carranza</who>
    <bug_when>2016-08-12 20:00:16 +0000</bug_when>
    <thetext>Verified on master commit : 6b66e9317f4ec3a69f98f29836aafa35b52f3fc7</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>