<?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>8747</bug_id>
          
          <creation_ts>2015-12-02 03:16:11 +0000</creation_ts>
          <short_desc>fix python md5/sha checksum incorrect on qemu86-64 with corei7-64 as DEFAULTTUNE</short_desc>
          <delta_ts>2015-12-07 13:32:54 +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>VERIFIED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>8748</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Undecided</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Hongxu Jia">hongxu.jia</reporter>
          <assigned_to name="Hongxu Jia">hongxu.jia</assigned_to>
          <cc>cristina-danielax.agurida</cc>
    
    <cc>liezhi.yang</cc>
    
    <cc>mark.hatle</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>ross.burton</cc>
          
          <qa_contact name="Cristina Agurida">cristina-danielax.agurida</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>56920</commentid>
    <comment_count>0</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2015-12-02 03:16:11 +0000</bug_when>
    <thetext>1. On qemux86-64, set corei7-64 to instaed of core2-64
diff --git a/meta/conf/machine/qemux86-64.conf b/meta/conf/machine/qemux86-64.conf
index 489194a..080ca79 100644
--- a/meta/conf/machine/qemux86-64.conf
+++ b/meta/conf/machine/qemux86-64.conf
@@ -8,8 +8,8 @@ PREFERRED_PROVIDER_virtual/libgles1 ?= &quot;mesa&quot;
 PREFERRED_PROVIDER_virtual/libgles2 ?= &quot;mesa&quot;
 
 require conf/machine/include/qemu.inc
-DEFAULTTUNE ?= &quot;core2-64&quot;
-require conf/machine/include/tune-core2.inc
+DEFAULTTUNE ?= &quot;corei7-64&quot;
+require conf/machine/include/tune-corei7.inc
 
 KERNEL_IMAGETYPE = &quot;bzImage&quot;

diff --git a/scripts/runqemu-internal b/scripts/runqemu-internal
index 3b0e54c..1543f94 100755
--- a/scripts/runqemu-internal
+++ b/scripts/runqemu-internal
@@ -442,7 +442,7 @@ if [ &quot;$MACHINE&quot; = &quot;qemux86-64&quot; ]; then
     if [ &quot;$KVM_ACTIVE&quot; = &quot;yes&quot; ]; then
         CPU_SUBTYPE=kvm64
     else
-        CPU_SUBTYPE=core2duo
+        CPU_SUBTYPE=Nehalem
     fi
     if [ ! -z &quot;$vga_option&quot; ]; then
         QEMU_UI_OPTIONS=&quot;$QEMU_UI_OPTIONS&quot;


2. Build core-image-minimal
$ bitbake core-image-minimal

3. Run qemu
$ runqemu qemux86-64 slirp nographic

4. Run python tests

root@qemux86-64:~# python /usr/lib/python2.7/test/test_md5.py   
test_basics (__main__.MD5_Test) ... FAIL
test_hexdigest (__main__.MD5_Test) ... FAIL
test_large_update (__main__.MD5_Test) ... ok

======================================================================
FAIL: test_basics (__main__.MD5_Test)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_md5.py&quot;, line 27, in test_basics
    eq(&apos;&apos;, &apos;d41d8cd98f00b204e9800998ecf8427e&apos;)
  File &quot;/usr/lib/python2.7/test/test_md5.py&quot;, line 23, in md5test
    self.assertEqual(md5(s).hexdigest(), expected)
AssertionError: &apos;d41d8cd98f00b204e90009080c08020e&apos; != &apos;d41d8cd98f00b204e9800998ecf8427e&apos;

======================================================================
FAIL: test_hexdigest (__main__.MD5_Test)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_md5.py&quot;, line 41, in test_hexdigest
    self.assertEqual(hexstr(m.digest()), h)
AssertionError: &apos;fdd9171bf32437e652bd753741b76a52&apos; != &apos;fdd9171bf32437e6520d050701070a02&apos;

----------------------------------------------------------------------
Ran 3 tests in 0.013s

FAILED (failures=2)
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_md5.py&quot;, line 61, in &lt;module&gt;
    test_main()
  File &quot;/usr/lib/python2.7/test/test_md5.py&quot;, line 58, in test_main
    test_support.run_unittest(MD5_Test)
  File &quot;/usr/lib/python2.7/test/test_support.py&quot;, line 1372, in run_unittest
    _run_suite(suite)
  File &quot;/usr/lib/python2.7/test/test_support.py&quot;, line 1355, in _run_suite
    raise TestFailed(err)
test.test_support.TestFailed: multiple errors occurred
root@qemux86-64:~# random: nonblocking pool is initialized

root@qemux86-64:~# python /usr/lib/python2.7/test/test_sha.py
test_case_1 (__main__.SHATestCase) ... FAIL
test_case_2 (__main__.SHATestCase) ... FAIL
test_case_3 (__main__.SHATestCase) ... FAIL
test_case_4 (__main__.SHATestCase) ... FAIL

======================================================================
FAIL: test_case_1 (__main__.SHATestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 37, in test_case_1
    &quot;a9993e364706816aba3e25717850c26c9cd0d89d&quot;)
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 21, in check
    self.assertTrue(computed == digest)
AssertionError: False is not true

======================================================================
FAIL: test_case_2 (__main__.SHATestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 41, in test_case_2
    &quot;84983e441c3bd26ebaae4aa1f95129e5e54670f1&quot;)
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 21, in check
    self.assertTrue(computed == digest)
AssertionError: False is not true

======================================================================
FAIL: test_case_3 (__main__.SHATestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 45, in test_case_3
    &quot;34aa973cd4c4daa4f61eeb2bdbad27316534016f&quot;)
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 21, in check
    self.assertTrue(computed == digest)
AssertionError: False is not true

======================================================================
FAIL: test_case_4 (__main__.SHATestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 49, in test_case_4
    &apos;4ca0ef38f1794b28a8f8ee110ee79d48ce13be25&apos;)
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 21, in check
    self.assertTrue(computed == digest)
AssertionError: False is not true

----------------------------------------------------------------------
Ran 4 tests in 0.165s

FAILED (failures=4)
Traceback (most recent call last):
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 56, in &lt;module&gt;
    test_main()
  File &quot;/usr/lib/python2.7/test/test_sha.py&quot;, line 52, in test_main
    test_support.run_unittest(SHATestCase)
  File &quot;/usr/lib/python2.7/test/test_support.py&quot;, line 1372, in run_unittest
    _run_suite(suite)
  File &quot;/usr/lib/python2.7/test/test_support.py&quot;, line 1355, in _run_suite
    raise TestFailed(err)
test.test_support.TestFailed: multiple errors occurred
root@qemux86-64:~#</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56921</commentid>
    <comment_count>1</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2015-12-02 03:17:16 +0000</bug_when>
    <thetext>The qemu didn&apos;t support gcc optimization level 3 very well,
in which the /usr/lib64/python2.7/test/test_sha.py and
/usr/lib64/python2.7/test/test_sha.py failed.

So we use gcc optimization level 2 to instead.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56924</commentid>
    <comment_count>2</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2015-12-02 05:01:19 +0000</bug_when>
    <thetext>The root cause if https://bugzilla.yoctoproject.org/show_bug.cgi?id=8747</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56929</commentid>
    <comment_count>3</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2015-12-02 09:50:26 +0000</bug_when>
    <thetext>(In reply to comment #2)
&gt; The root cause if https://bugzilla.yoctoproject.org/show_bug.cgi?id=8747

https://bugzilla.yoctoproject.org/show_bug.cgi?id=8748</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57002</commentid>
    <comment_count>4</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2015-12-03 15:57:34 +0000</bug_when>
    <thetext>There&apos;s no point working around this in Python when qemu is broken.  Marking as a duplicate.

*** This bug has been marked as a duplicate of bug 8748 ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57080</commentid>
    <comment_count>5</comment_count>
    <who name="Cristina Agurida">cristina-danielax.agurida</who>
    <bug_when>2015-12-07 13:32:54 +0000</bug_when>
    <thetext>Duplicate of bug 8748.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>