<?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>238</bug_id>
          
          <creation_ts>2010-08-27 04:18:33 +0000</creation_ts>
          <short_desc>sstate code doesn&apos;t detect overwriting files</short_desc>
          <delta_ts>2012-09-28 13:54:01 +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>Meta-yocto</product>
          <component>meta-yocto</component>
          <version>0.9</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>(Scheduled)</status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>1.3 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Richard Purdie">richard.purdie</reporter>
          <assigned_to name="Richard Purdie">richard.purdie</assigned_to>
          <cc>alexandrux.palalau</cc>
    
    <cc>dexuan.cui</cc>
    
    <cc>gary</cc>
    
    <cc>jessica.zhang</cc>
    
    <cc>kevin.tian</cc>
    
    <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>richard.purdie</cc>
    
    <cc>sgw</cc>
    
    <cc>song.liu</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>9442</commentid>
    <comment_count>0</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2010-08-27 04:18:33 +0000</bug_when>
    <thetext>Two packages should not be able to install the same filename to a sstate location without raising an error.

Currently the code silently overwrites the file and there is no duplicate detection.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11651</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2011-02-01 11:17:01 +0000</bug_when>
    <thetext>We can check for overwritten files from the shell now:

cd tmp/sstate-control
cat * | sort | uniq -d | grep -v /$

which on a small build I had lying around resulted in:

/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/fonts/X11/misc/fonts.alias
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/info/bfd.info
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/info/configure.info
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/info/dir
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/info/standards.info
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man1/kill.1
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man1/last.1
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man1/mesg.1
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man1/wall.1
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man3/libblkid.3
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/blkid.8
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/findfs.8
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/fsck.8
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/halt.8
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/reboot.8
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/shutdown.8
/media/build2/builds/rptest/b4/tmp/sysroots/qemux86/usr/share/man/man8/uuidd.8
/media/build2/builds/rptest/b4/tmp/sysroots/x86_64-linux/usr/share/info/dir
/media/build2/builds/rptest/b4/tmp/sysroots/x86_64-linux/usr/share/man/man3/libblkid.3
/media/build2/builds/rptest/b4/tmp/sysroots/x86_64-linux/usr/share/man/man8/blkid.8
/media/build2/builds/rptest/b4/tmp/sysroots/x86_64-linux/usr/share/man/man8/findfs.8
/media/build2/builds/rptest/b4/tmp/sysroots/x86_64-linux/usr/share/man/man8/fsck.8
/media/build2/builds/rptest/b4/tmp/sysroots/x86_64-linux/usr/share/man/man8/uuidd.8

not too bad at least since its mainly man/doc data</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11911</commentid>
    <comment_count>2</comment_count>
    <who name="Dexuan Cui">dexuan.cui</who>
    <bug_when>2011-02-21 21:31:33 +0000</bug_when>
    <thetext>(In reply to comment #1)
&gt; We can check for overwritten files from the shell now:
&gt; cd tmp/sstate-control
&gt; cat * | sort | uniq -d | grep -v /$
&gt; which on a small build I had lying around resulted in: ...
&gt; not too bad at least since its mainly man/doc data

I built poky-image-sato-sdk and meta-toolchain-sdk recently and here is my list:

root@dcui-desktop:/distro/dcui/110214/p1/qemumips/tmp/sstate-control# cat * | sort | uniq -d | grep -v /$
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-linux/usr/share/man/man3/libblkid.3
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-linux/usr/share/man/man8/blkid.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-linux/usr/share/man/man8/findfs.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-linux/usr/share/man/man8/fsck.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-linux/usr/share/man/man8/uuidd.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-nativesdk-pokysdk-linux/opt/poky/0.9+snapshot/sysroots/i686-pokysdk-linux/usr/share/info/dir.old
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-pokysdk-linux-nativesdk/opt/poky/0.9+snapshot/sysroots/i686-pokysdk-linux/usr/share/info/bfd.info
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-pokysdk-linux-nativesdk/opt/poky/0.9+snapshot/sysroots/i686-pokysdk-linux/usr/share/info/configure.info
/distro/dcui/110214/p1/qemumips/tmp/sysroots/i686-pokysdk-linux-nativesdk/opt/poky/0.9+snapshot/sysroots/i686-pokysdk-linux/usr/share/info/standards.info
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/lib/libiberty.a
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/info/bfd.info
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/info/configure.info
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/info/dir
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/info/dir.old
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/info/standards.info
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man1/kill.1
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man1/last.1
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man1/mesg.1
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man1/wall.1
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man3/libblkid.3
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/blkid.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/findfs.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/fsck.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/halt.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/reboot.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/shutdown.8
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/share/man/man8/uuidd.8


What&apos;s notable is:
Both binutils and gcc supplies 
/distro/dcui/110214/p1/qemumips/tmp/sysroots/qemumips/usr/lib/libiberty.a

Hi Richard, IIRC, you said we could use the one binutils supplies(I&apos;m not clear about the exact reason)? So we should discard the one gcc supplies?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11927</commentid>
    <comment_count>3</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2011-02-22 03:55:59 +0000</bug_when>
    <thetext>Yes, we shouldn&apos;t stage the one from gcc and always use the one from binutils instead (we just have to make a clear choice and this makes the most sense).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>20011</commentid>
    <comment_count>4</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2012-04-06 16:27:57 +0000</bug_when>
    <thetext>*** Bug 2235 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>24720</commentid>
    <comment_count>5</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2012-09-01 23:01:41 +0000</bug_when>
    <thetext>http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=59260f952f8687ac67a17035307c6c0792728f1b</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>25925</commentid>
    <comment_count>6</comment_count>
    <who name="Alexandru Palalau">alexandrux.palalau</who>
    <bug_when>2012-09-28 13:54:01 +0000</bug_when>
    <thetext>Verified on master branch, latest commit ID a8c78aa835b06578759c4ca170f759928bac3efd
After building core-image-sato-sdk and meta-toolchain-sdk the mentioned cat command provided no output.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>