<?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>15494</bug_id>
          
          <creation_ts>2024-05-24 15:28:23 +0000</creation_ts>
          <short_desc>[Dropbear] dropbear.inc creates an absolute systemlink, even though Yocto only allows relative syslinks</short_desc>
          <delta_ts>2024-05-30 14:41:05 +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>4.0.1</version>
          <rep_platform>Other</rep_platform>
          <op_sys>arm</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>NOTABUG</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>critical</bug_severity>
          <target_milestone>0.0.0</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Erik">erik.burghardt</reporter>
          <assigned_to name="Unassigned">unassigned</assigned_to>
          <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>tgamblin</cc>
    
    <cc>zyckk4</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>99082</commentid>
    <comment_count>0</comment_count>
    <who name="Erik">erik.burghardt</who>
    <bug_when>2024-05-24 15:28:23 +0000</bug_when>
    <thetext>This bug can be found in poky/meta/recipes-core/dropbear/dropbear.inc in kirkstone-4.0.12. It was only tested on this version
It can still be found in scarthgap, even though in another file: poky/meta/recipes-core/dropbear/dropbear_2022.83.bb.

The bug appears in the following way:
1. You import dropbear-native:do_populate_sysroot somewhere like in this .bbclass:
do_image_qemu_disk[depends] = &quot; \
    gptfdisk-native:do_populate_sysroot \
    e2fsprogs-native:do_populate_sysroot \
    virtual/fakeroot-native:do_populate_sysroot \
    dropbear-native:do_populate_sysroot \
&quot;
2. This calls dropbear.inc
3. In dropbear.inc, there are the following lines:
ln -s ${sbindir}/dropbearmulti ${D}${bindir}/$i
and
ln -s ./dropbearmulti ${D}${sbindir}/$i

Both lines create syslinks with absolute paths.
4. This leads to the following error, when building:
ERROR: dropbear-native-2020.81-r0 do_populate_sysroot: sstate found an absolute path symlink /home/yocto/build/tmp/work/x86_64-linux/dropbear-native/2020.81-r0/sysroot-destdir/home/yocto/build/tmp/work/x86_64-linux/dropbear-native/2020.81-r0/recipe-sysroot-native/usr/bin/dbclient pointing at /home/yocto/build/tmp/work/x86_64-linux/dropbear-native/2020.81-r0/recipe-sysroot-native/usr/sbin/dropbearmulti. Please replace this with a relative link.
5. An important fact:
When you build this the first time, it will give this error. If you then build it again without changes, the build will succeed, so it seems something that makes the second build happy is cached in the first build. You can force the build to error again by running &quot;bitbake -c cleanall dropbear-native&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>99101</commentid>
    <comment_count>1</comment_count>
    <who name="Trevor Gamblin">tgamblin</who>
    <bug_when>2024-05-30 14:39:40 +0000</bug_when>
    <thetext>Can you clarify why dropbear native is being built? The core recipe does not mention it anywhere, so it is not expected that a native build should work. Binaries are only installed into native sysroots, so this won&apos;t affect target builds.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>99102</commentid>
    <comment_count>2</comment_count>
    <who name="Trevor Gamblin">tgamblin</who>
    <bug_when>2024-05-30 14:39:58 +0000</bug_when>
    <thetext>Marked as NOTABUG until further info/justification is provided.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>