<?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>14839</bug_id>
          
          <creation_ts>2022-06-16 13:45:42 +0000</creation_ts>
          <short_desc>nettle 3.8 is not reproducible (executable is a sparse file)</short_desc>
          <delta_ts>2022-09-22 14:51:36 +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>WORKSFORME</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard>AB-INT</status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>4.1</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alexandre Belloni">alexandre.belloni</reporter>
          <assigned_to name="Unassigned">unassigned</assigned_to>
          <cc>alexandre.belloni</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>sundeep.kokkonda</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>93511</commentid>
    <comment_count>0</comment_count>
    <who name="Alexandre Belloni">alexandre.belloni</who>
    <bug_when>2022-06-16 13:45:42 +0000</bug_when>
    <thetext>This is possibly not related to nettle:

https://autobuilder.yoctoproject.org/typhoon/#/builders/117/builds/985/steps/13/logs/stdio

reproducible debian9-ty-2

https://autobuilder.yocto.io/pub/repro-fail/oe-reproducible-20220609-5bq03hze/packages/diff-html/

From Richard:

&quot;&quot;&quot;
In poking around the build directory which I saved, somehow
/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test ends up as a sparse file
filled with zeros, which then results in the .debug version not being
created.

pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0/packages-split/nettle-ptest/usr/lib/nettle/ptest/testsuite$ file ecc-sqrt-test
ecc-sqrt-test: data
pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0/packages-split/nettle-ptest/usr/lib/nettle/ptest/testsuite$ file ecc-add-test
ecc-add-test: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-x86-64.so.2, BuildID[sha1]=2f7e2d2fc004a51e52f70ba68dcd5a805d590b3e, for GNU/Linux 3.2.0, not stripped

pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0$ file package/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
package/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test: data
pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0$ file image/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
image/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-x86-64.so.2, BuildID[sha1]=f5dff0233b77a0bfc20554295d1e1fac6a273b9d, for GNU/Linux 3.2.0,
not stripped

pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0$ ls -la image/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
-rwxr-xr-x 1 pokybuild pokybuild 321216 Jun  9 02:00 image/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0$ ls -la package/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
-rwxr-xr-x 2 pokybuild pokybuild 321216 Jun  2 17:57 package/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test

pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0$ du -h image/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
316K    image/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
pokybuild@debian9-ty-2:~/yocto-worker/reproducible/build/build-st/reproducibleB/tmp/work/core2-64-poky-linux/nettle/3.8-r0$ du -h package/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test
0	package/usr/lib/nettle/ptest/testsuite/ecc-sqrt-test

so somewhere between the file being created in image/ (in do_install)
and the file in package/ in do_package, it is corrupted but has the
right size and is sparse.

This suggests our packaging code has broken somewhere along the way.

Nothing in the pseudo log or in the do_package log. I have the saved
build directory but not sure there is anything else to learn from it
:/.
&quot;&quot;&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93521</commentid>
    <comment_count>1</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2022-06-16 14:46:04 +0000</bug_when>
    <thetext>Our reproducible builds will fail if this happens so this appears to be a very rare error. If someone wants to review objdump and other tools that would be interesting. One could also use inotify or lttng to monitor the file in question.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>94057</commentid>
    <comment_count>2</comment_count>
    <who name="Alexandre Belloni">alexandre.belloni</who>
    <bug_when>2022-09-22 14:51:36 +0000</bug_when>
    <thetext>It didn&apos;t reproduce in a while and we suspect a rare race condition in binutils</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>