<?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>12095</bug_id>
          
          <creation_ts>2017-09-16 22:26:37 +0000</creation_ts>
          <short_desc>Toolchain.Host.Mismatch problem</short_desc>
          <delta_ts>2017-12-08 19:09:06 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>6</classification_id>
          <classification>Yocto Project Subprojects</classification>
          <product>ADT</product>
          <component>adt</component>
          <version>2.4</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.5 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Dvorkin Dmitry">dvorkin</reporter>
          <assigned_to name="Chin Huat Ang">chin.huat.ang</assigned_to>
          <cc>poky.adt.watcher</cc>
    
    <cc>poky.watcher</cc>
          
          <qa_contact name="Libertad">libertad.gonzalez.de.la.cruz</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>76914</commentid>
    <comment_count>0</comment_count>
    <who name="Dvorkin Dmitry">dvorkin</who>
    <bug_when>2017-09-16 22:26:37 +0000</bug_when>
    <thetext>My Linux is x86_64.
I built SDK for i686 + arm to easily run on 32bit Linux versions (i686).
I installed Eclipse x86_64 and tryed to configure my i686 SDK at Yocto ADT plugin. No success. It says, SDK arch and host arch are different.

I used my i686 SDK in my x86_64 Linux without problems for year. Why Eclipse ADT plugin complains? If I&apos;ll build x86_86 SDK I allowed to use it with my Eclipse x86_64.

The wrong check (it says, I can&apos;t use i686 gcc to build with Eclipse x86_64!) forces me to change my SDK to x86_64 arch and stop supporintg i686. Or build two SDKs for i686 and x86_64.

I think, line 149 of http://git.yoctoproject.org/cgit/cgit.cgi/eclipse-poky-contrib/tree/plugins/org.yocto.sdk.ide/src/org/yocto/sdk/ide/YoctoSDKChecker.java#n149 is completely incorrect.

the check has to be about like this:

if ( host_arch != &quot;x86_64&quot; &amp;&amp; sdk_arch != host_arch) return( MISMATCH);

or:

if ( host_arch LIKE &quot;i\d\d\d&quot; &amp;&amp; sdk_arch != host_arch) return( MISMATCH);

or (more strict, using JavaScript syntax):

ha = host_arch.replace( &apos;i&apos;, &apos;&apos;).replace( &apos;_&apos;, &apos;&apos;).toInt()
sa = sdk_arch.replace( &apos;i&apos;, &apos;&apos;).replace( &apos;_&apos;, &apos;&apos;).toInt();
if ( sa &gt; ha) return( MISMATCH);</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>77215</commentid>
    <comment_count>1</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2017-09-28 23:27:39 +0000</bug_when>
    <thetext>Question:

I commented out the sdk check as a quick test and found that for autotools at least, the configure fails if I use a 586 sdk on an x86-64 host .  It fails due to gcc failing to find libgcc and fails to find crtbegin.o.

If i source the 586 env from a shell I see the same failure if I try to build a hello.c. 

How were you building with the 586 sdk from the command line?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>77378</commentid>
    <comment_count>2</comment_count>
    <who name="Dvorkin Dmitry">dvorkin</who>
    <bug_when>2017-10-05 07:36:37 +0000</bug_when>
    <thetext>I&apos;m building programs with my cross-gcc from i686 SDK without problems.
I&apos;m using i686 SDK, built from scratch with yocto on my Mageia distribution.
No external libraries/gcc used, except SDL/libsdl-native.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>77426</commentid>
    <comment_count>3</comment_count>
    <who name="Stephen K Jolley">sjolley.yp.pm</who>
    <bug_when>2017-10-06 13:59:46 +0000</bug_when>
    <thetext>Brian, I believe the question was answered.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78610</commentid>
    <comment_count>4</comment_count>
    <who name="brian avery">brian.avery</who>
    <bug_when>2017-12-08 19:09:06 +0000</bug_when>
    <thetext>Given current resources, we won&apos;t be able to address this. Suggested workaround is to build both the 32 and 64 bit sdks.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>