<?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>14520</bug_id>
          
          <creation_ts>2021-08-20 16:15:46 +0000</creation_ts>
          <short_desc>A qemuboot.conf file isn&apos;t generated if the rootfs wasn&apos;t modified</short_desc>
          <delta_ts>2026-07-03 11:09:51 +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>unspecified</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></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>6.1 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Kristian Klausen">kristian</reporter>
          <assigned_to name="Siva Balasubramanian">sivakumar.bs</assigned_to>
          <cc>akuster808</cc>
    
    <cc>ccasciato</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>sivakumar.bs</cc>
    
    <cc>tgamblin</cc>
    
    <cc>tim.orling</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>91244</commentid>
    <comment_count>0</comment_count>
    <who name="Kristian Klausen">kristian</who>
    <bug_when>2021-08-20 16:15:46 +0000</bug_when>
    <thetext>qemuboot is added as a task like so[1]:
addtask do_write_qemuboot_conf after do_rootfs before do_image

This means do_write_qemuboot_conf is only run if do_rootfs is run, which isn&apos;t always the case. In my case I have been tweaking the initramfs and a new image was created but not a corresponding .qemuboot.conf file, which caused some frustration as runqemu was booting the old image.

[1] https://git.openembedded.org/openembedded-core/tree/meta/classes/qemuboot.bbclass?id=4e9a06b64b43131b731fb59a0305f78a98e27fbd#n104</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96081</commentid>
    <comment_count>1</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-07-26 21:22:02 +0000</bug_when>
    <thetext>Bulk move of 64 bugs to 4.3 M3 after a quick review.
If a bug is actually fixed, please add a commit link and resolve it.
-- Randy for YP bug team.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96478</commentid>
    <comment_count>2</comment_count>
    <who name="Trevor Gamblin">tgamblin</who>
    <bug_when>2023-09-14 16:44:41 +0000</bug_when>
    <thetext>Moved to M4.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>97046</commentid>
    <comment_count>3</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-10-30 15:29:06 +0000</bug_when>
    <thetext>Bulk move to 5.0 M1. -- Randy</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>97693</commentid>
    <comment_count>4</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-12-21 23:28:33 +0000</bug_when>
    <thetext>Bulk move of 52 5.0-M1 bugs to M2.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>98005</commentid>
    <comment_count>5</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2024-01-25 14:28:48 +0000</bug_when>
    <thetext>Bulk move of bugs owned by &quot;unassigned&quot; from 5.0-M2 to 5.0-M3.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>98290</commentid>
    <comment_count>6</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2024-02-22 19:53:20 +0000</bug_when>
    <thetext>Bulk move of bugs from 5.0-M3 to 5.99.
The bugs in this list are all unassigned and are ones that I consider to be nice to do some time but not essential track from milestone to milestone in 5.0 or 5.1. We agreed on this bug handling approach in the YP bug review on Feb 22, 2024.

If you disagree, please move back to a 5.[012...]-M* milestone.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>104711</commentid>
    <comment_count>7</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2026-03-18 22:16:01 +0000</bug_when>
    <thetext>Kristian,

Reviewing old bugs.
Is this still a problem on the master branch ?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105377</commentid>
    <comment_count>8</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2026-05-07 14:58:45 +0000</bug_when>
    <thetext>Quan please re-test.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105378</commentid>
    <comment_count>9</comment_count>
    <who name="Tim Orling">tim.orling</who>
    <bug_when>2026-05-07 14:59:50 +0000</bug_when>
    <thetext>https://git.openembedded.org/openembedded-core/tree/meta/classes-recipe/qemuboot.bbclass#n130</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105692</commentid>
    <comment_count>10</comment_count>
    <who name="Siva Balasubramanian">sivakumar.bs</who>
    <bug_when>2026-06-01 17:07:26 +0000</bug_when>
    <thetext>Reproduced on current master (linux-yocto 6.18.33, core-image-minimal,
qemux86-64).

After rebuilding only the kernel (bitbake -c cleansstate linux-yocto),
the .qemuboot.conf symlink retained the old timestamp while ext4.zst
was updated to a new one.

Fix: add do_write_qemuboot_conf[depends] += &quot;${KERNEL_DEPLOY_DEPEND}&quot;
KERNEL_DEPLOY_DEPEND is already used by do_build[depends] in
image.bbclass for the same reason and handles firmware/baremetal
images since it is defined with ?=.

v2 patch submitted to openembedded-core mailing list:
https://lists.openembedded.org/g/openembedded-core/topic/patch_v2_qemuboot_bbclass/119596210</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105695</commentid>
    <comment_count>11</comment_count>
    <who name="Siva Balasubramanian">sivakumar.bs</who>
    <bug_when>2026-06-02 11:45:52 +0000</bug_when>
    <thetext>v3 patch submitted fixing the autobuilder failure reported on v2.

Root cause: baremetal images inherit qemuboot via baremetal-image.bbclass
but do not set KERNEL_DEPLOY_DEPEND, causing a parse error when empty
string was passed to [depends].

Fix uses a Python expression to guard against the empty case:
  do_write_qemuboot_conf[depends] += &quot;${@d.getVar(&apos;KERNEL_DEPLOY_DEPEND&apos;) or &apos;&apos;}&quot;

Tested:
- do_write_qemuboot_conf reruns correctly after kernel rebuild on qemux86-64
- 949 recipes parse cleanly with MACHINE=qemuarm, no errors

v3 patch: https://lists.openembedded.org/g/openembedded-core/topic/patch_v3_qemuboot_bbclass/119609347</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105855</commentid>
    <comment_count>12</comment_count>
    <who name="Siva Balasubramanian">sivakumar.bs</who>
    <bug_when>2026-06-12 09:01:24 +0000</bug_when>
    <thetext>v4 patch submitted fixing the circular dependency reported on v3.

Root cause of circular dependency: when INITRAMFS_IMAGE_BUNDLE=1,
linux-yocto:do_deploy depends on the initramfs image completing first,
so adding an unconditional kernel deploy dependency on
do_write_qemuboot_conf created a cycle back into the initramfs image.

Fix skips the kernel deploy dependency when INITRAMFS_IMAGE_BUNDLE=1:
  do_write_qemuboot_conf[depends] += &quot;${@ &apos;&apos; if bb.utils.to_boolean(d.getVar(&apos;INITRAMFS_IMAGE_BUNDLE&apos;)) else (d.getVar(&apos;KERNEL_DEPLOY_DEPEND&apos;) or &apos;&apos;)}&quot;

Tested:
- do_write_qemuboot_conf reruns correctly after kernel rebuild on qemux86-64
- 949 recipes parse cleanly with MACHINE=qemuarm, no errors
- bitbake -g with INITRAMFS_IMAGE_BUNDLE=1 confirms no circular dependency

https://lists.openembedded.org/g/openembedded-core/topic/patch_v4_qemuboot_bbclass/119770767</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105857</commentid>
    <comment_count>13</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2026-06-12 13:49:48 +0000</bug_when>
    <thetext>Thanks for working on this Siva.
Quan isn&apos;t available right now so assigning to you.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105865</commentid>
    <comment_count>14</comment_count>
    <who name="Siva Balasubramanian">sivakumar.bs</who>
    <bug_when>2026-06-15 07:40:58 +0000</bug_when>
    <thetext>Thank you Randy. I will monitor v4 on the mailing list and address
any further review comments promptly.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>106092</commentid>
    <comment_count>15</comment_count>
    <who name="Siva Balasubramanian">sivakumar.bs</who>
    <bug_when>2026-07-03 11:09:51 +0000</bug_when>
    <thetext>https://git.openembedded.org/openembedded-core/commit/?id=ed97056104ed2b97a687f956b49be7241862be53</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>