<?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>10338</bug_id>
          
          <creation_ts>2016-09-28 08:47:18 +0000</creation_ts>
          <short_desc>perl-native embeds host-dependent variables in sysroot</short_desc>
          <delta_ts>2017-01-17 14:01:28 +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>2.2</version>
          <rep_platform>All</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc>http://errors.yoctoproject.org/Errors/Details/109589/</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.3 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Joshua Lock">joshuagloe</reporter>
          <assigned_to name="Aníbal Limón">anibal.limon</assigned_to>
          <cc>eduard.bartosh</cc>
    
    <cc>jose.perez.carranza</cc>
    
    <cc>leonardo.sandoval.gonzalez</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>ross.burton</cc>
          
          <qa_contact name="David Lopez Barriba">davidx.lopez.barriba</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>66666</commentid>
    <comment_count>0</comment_count>
    <who name="Joshua Lock">joshuagloe</who>
    <bug_when>2016-09-28 08:47:18 +0000</bug_when>
    <thetext>When building the build-appliance on the autobuilder for current master-next (7acd5a5d2af3ca0becb5360103f930abad6560cb) libxml-parser-perl-native fails in do_compile:

ERROR: libxml-parser-perl-native-2.44-r0 do_compile: oe_runmake failed
ERROR: libxml-parser-perl-native-2.44-r0 do_compile: Function failed: do_compile (log file is located at /home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/work/x86_64-linux/libxml-parser-perl-native/2.44-r0/temp/log.do_compile.4709)
ERROR: Logfile of failure stored in: /home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/work/x86_64-linux/libxml-parser-perl-native/2.44-r0/temp/log.do_compile.4709
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 16 PASTHRU_INC=-isystem/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe LD=gcc
| ERROR: oe_runmake failed
| make[1]: Entering directory &apos;/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/work/x86_64-linux/libxml-parser-perl-native/2.44-r0/XML-Parser-2.44/Expat&apos;
| &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/bin/perl-native/perl&quot; &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/lib/perl-native/perl/5.22.1/ExtUtils/xsubpp&quot; -noprototypes -typemap &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/lib/perl-native/perl/5.22.1/ExtUtils/typemap&quot; -typemap &quot;typemap&quot;  Expat.xs &gt; Expat.xsc &amp;&amp; mv Expat.xsc Expat.c
| cp Expat.pm ../blib/lib/XML/Parser/Expat.pm
| Running Mkbootstrap for XML::Parser::Expat ()
| cp Parser/Style/Subs.pm blib/lib/XML/Parser/Style/Subs.pm
| cp Parser/Style/Objects.pm blib/lib/XML/Parser/Style/Objects.pm
| cp Parser/Encodings/iso-8859-5.enc blib/lib/XML/Parser/Encodings/iso-8859-5.enc
| cp Parser/Style/Tree.pm blib/lib/XML/Parser/Style/Tree.pm
| cp Parser/Encodings/koi8-r.enc blib/lib/XML/Parser/Encodings/koi8-r.enc
| cp Parser/Encodings/x-sjis-cp932.enc blib/lib/XML/Parser/Encodings/x-sjis-cp932.enc
| cp Parser/Encodings/iso-8859-4.enc blib/lib/XML/Parser/Encodings/iso-8859-4.enc
| cp Parser/Encodings/iso-8859-3.enc blib/lib/XML/Parser/Encodings/iso-8859-3.enc
| cp Parser.pm blib/lib/XML/Parser.pm
| cp Parser/Style/Debug.pm blib/lib/XML/Parser/Style/Debug.pm
| cp Parser/Encodings/euc-kr.enc blib/lib/XML/Parser/Encodings/euc-kr.enc
| cp Parser/Encodings/x-sjis-jdk117.enc blib/lib/XML/Parser/Encodings/x-sjis-jdk117.enc
| cp Parser/Encodings/windows-1251.enc blib/lib/XML/Parser/Encodings/windows-1251.enc
| cp Parser/Encodings/big5.enc blib/lib/XML/Parser/Encodings/big5.enc
| cp Parser/Encodings/iso-8859-9.enc blib/lib/XML/Parser/Encodings/iso-8859-9.enc
| cp Parser/Encodings/iso-8859-2.enc blib/lib/XML/Parser/Encodings/iso-8859-2.enc
| cp Parser/Encodings/windows-1255.enc blib/lib/XML/Parser/Encodings/windows-1255.enc
| cp Parser/LWPExternEnt.pl blib/lib/XML/Parser/LWPExternEnt.pl
| cp Parser/Style/Stream.pm blib/lib/XML/Parser/Style/Stream.pm
| cp Parser/Encodings/ibm866.enc blib/lib/XML/Parser/Encodings/ibm866.enc
| cp Parser/Encodings/windows-1250.enc blib/lib/XML/Parser/Encodings/windows-1250.enc
| cp Parser/Encodings/iso-8859-8.enc blib/lib/XML/Parser/Encodings/iso-8859-8.enc
| cp Parser/Encodings/Japanese_Encodings.msg blib/lib/XML/Parser/Encodings/Japanese_Encodings.msg
| cp Parser/Encodings/x-euc-jp-unicode.enc blib/lib/XML/Parser/Encodings/x-euc-jp-unicode.enc
| cp Parser/Encodings/x-euc-jp-jisx0221.enc blib/lib/XML/Parser/Encodings/x-euc-jp-jisx0221.enc
| cp Parser/Encodings/windows-1252.enc blib/lib/XML/Parser/Encodings/windows-1252.enc
| cp Parser/Encodings/x-sjis-jisx0221.enc blib/lib/XML/Parser/Encodings/x-sjis-jisx0221.enc
| cp Parser/Encodings/x-sjis-unicode.enc blib/lib/XML/Parser/Encodings/x-sjis-unicode.enc
| cp Parser/Encodings/README blib/lib/XML/Parser/Encodings/README
| cp Parser/Encodings/iso-8859-7.enc blib/lib/XML/Parser/Encodings/iso-8859-7.enc
| chmod 644 &quot;Expat.bs&quot;
| gcc  -c -isystem/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe -I/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/include -D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2   -DVERSION=\&quot;2.44\&quot; -DXS_VERSION=\&quot;2.44\&quot; -fPIC &quot;-I/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/sysroots/x86_64-linux/usr/lib/perl-native/perl/5.22.1/CORE&quot;   Expat.c
| gcc: error: unrecognized command line option ‘-fstack-protector-strong’
| Makefile:323: recipe for target &apos;Expat.o&apos; failed
| make[1]: *** [Expat.o] Error 1
| make[1]: Leaving directory &apos;/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/work/x86_64-linux/libxml-parser-perl-native/2.44-r0/XML-Parser-2.44/Expat&apos;
| Makefile:594: recipe for target &apos;subdirs&apos; failed
| make: *** [subdirs] Error 2
| WARNING: /home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/work/x86_64-linux/libxml-parser-perl-native/2.44-r0/temp/run.do_compile.4709:1 exit 1 from &apos;exit 1&apos;
| ERROR: Function failed: do_compile (log file is located at /home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/build/tmp/work/x86_64-linux/libxml-parser-perl-native/2.44-r0/temp/log.do_compile.4709)
NOTE: recipe libxml-parser-perl-native-2.44-r0: task do_compile: Failed
ERROR: Task (virtual:native:/home/pokybuild/yocto-autobuilder/yocto-worker/build-appliance/build/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb:do_compile) failed with exit code &apos;1&apos;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66677</commentid>
    <comment_count>1</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2016-09-28 11:54:10 +0000</bug_when>
    <thetext>So what happens here is that perl-native compiles on a machine with a host GCC that supports -fstack-protector=strong, and it embeds that option into usr/lib/perl-native/perl/config.sh (and more) in the native sysroot.  One of these files is then used by makemaker to determine what options to use when building.  This failure happens if perl-native comes from sstate via a machine which supports -fstack-protector=strong but the machine building say libperl-parser-xml-native has an older GCC release which does not support it.

I guess we should strip these options out post-configure in native builds?

Frantically reassigning to Anibal as he is the perl maintainer.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>68778</commentid>
    <comment_count>2</comment_count>
    <who name="Aníbal Limón">anibal.limon</who>
    <bug_when>2016-12-01 16:00:08 +0000</bug_when>
    <thetext>I hit this error on local AB, i will try to fix avoiding usage of -fstack-protector=strong or add a test to review if it&apos;s supported.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>68783</commentid>
    <comment_count>3</comment_count>
    <who name="Aníbal Limón">anibal.limon</who>
    <bug_when>2016-12-01 16:33:22 +0000</bug_when>
    <thetext>Patch sent for review,

http://lists.openembedded.org/pipermail/openembedded-core/2016-December/129528.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>69090</commentid>
    <comment_count>4</comment_count>
    <who name="Aníbal Limón">anibal.limon</who>
    <bug_when>2016-12-13 17:59:07 +0000</bug_when>
    <thetext>There is other patch that also fixes the problem but currently brokes eSDK so waiting to be merge,

http://lists.openembedded.org/pipermail/openembedded-core/2016-November/128510.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>69624</commentid>
    <comment_count>5</comment_count>
    <who name="Aníbal Limón">anibal.limon</who>
    <bug_when>2017-01-09 16:33:03 +0000</bug_when>
    <thetext>This patch [1] solves the issue because the sstate generated is different in gcc &lt; 4.9 and &gt; 4.9.

[1] http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=c21cec84886d9c70396e9be0ceb9a8ef300b54be</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>