<?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>13487</bug_id>
          
          <creation_ts>2019-08-20 22:36:05 +0000</creation_ts>
          <short_desc>systemd: meson_options.txt defaults to build host gnu-efi include paths</short_desc>
          <delta_ts>2019-08-22 14:42:34 +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>3.0</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <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="Chin Huat Ang">chin.huat.ang</reporter>
          <assigned_to name="Ross Burton">ross.burton</assigned_to>
          <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>richard.purdie</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>84714</commentid>
    <comment_count>0</comment_count>
    <who name="Chin Huat Ang">chin.huat.ang</who>
    <bug_when>2019-08-20 22:36:05 +0000</bug_when>
    <thetext>Building systemd on build host with gnu-efi triggers the following compile-host-path QA error:

ERROR: QA Issue: systemd: The compile log indicates that host include and/or library paths were used.

It looks like systemd recipe needs PACKAGECONFIG gnu-efi so that it doesn&apos;t assume host gnu-efi:

https://github.com/systemd/systemd-stable/blob/v242-stable/meson_options.txt#L304

log.do_configure reported these host paths:

         EFI lib directory:                 /usr/lib                                                                                                                                      
         EFI lds directory:                 /usr/lib                                                                                                                                      
         EFI include directory:             /usr/include/efi   

log.do_compile contains the following warnings:

cc1: warning: include location &quot;/usr/include/efi&quot; is unsafe for cross-compilation [-Wpoison-system-directories]
cc1: warning: include location &quot;/usr/include/efi/x86_64&quot; is unsafe for cross-compilation [-Wpoison-system-directories]
cc1: warning: SSE instruction set disabled, using 387 arithmetics
x86_64-oe-linux-ld: warning: library search path &quot;/usr/lib&quot; is unsafe for cross-compilation</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84715</commentid>
    <comment_count>1</comment_count>
    <who name="Chin Huat Ang">chin.huat.ang</who>
    <bug_when>2019-08-20 22:41:13 +0000</bug_when>
    <thetext>Probably add this line to systemd recipe:

PACKAGECONFIG[gnu-efi] = &quot;-Dgnu-efi=true -Defi-libdir=${STAGING_LIBDIR} -Defi-includedir=${STAGING_INCDIR}/efi,-Dgnu-efi=false,gnu-efi&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84716</commentid>
    <comment_count>2</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2019-08-21 10:26:52 +0000</bug_when>
    <thetext>Filed upstream at https://github.com/systemd/systemd/issues/13371</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84717</commentid>
    <comment_count>3</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2019-08-21 10:59:18 +0000</bug_when>
    <thetext>Tested that oneliner, patch sent.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84726</commentid>
    <comment_count>4</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2019-08-22 14:42:34 +0000</bug_when>
    <thetext>http://git.yoctoproject.org/cgit.cgi/poky/commit/?h=master&amp;id=58ab85d3e005476ab5bcc288ad421c0c5d1e0582</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>