<?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>4410</bug_id>
          
          <creation_ts>2013-04-24 11:04:02 +0000</creation_ts>
          <short_desc>systemd: do_compile failed in parallel builds with system&apos;s make 3.28</short_desc>
          <delta_ts>2013-04-25 09:53:10 +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>1.6</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>1.5</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Hongxu Jia">hongxu.jia</reporter>
          <assigned_to name="Hongxu Jia">hongxu.jia</assigned_to>
          <cc>hongxu.jia</cc>
    
    <cc>liezhi.yang</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>ning.zhang</cc>
    
    <cc>Qi.Chen</cc>
    
    <cc>ross.burton</cc>
    
    <cc>sen.zhang</cc>
    
    <cc>sgw</cc>
    
    <cc>yi.zhao</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>32578</commentid>
    <comment_count>0</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2013-04-24 11:04:02 +0000</bug_when>
    <thetext>*env:
Build Configuration:
BB_VERSION        = &quot;1.18.0&quot;
BUILD_SYS         = &quot;x86_64-linux&quot;
NATIVELSBSTRING   = &quot;SUSE-LINUX-12.1&quot;
TARGET_SYS        = &quot;x86_64-poky-linux&quot;
MACHINE           = &quot;qemux86-64&quot;
DISTRO            = &quot;poky&quot;
DISTRO_VERSION    = &quot;1.4&quot;
TUNE_FEATURES     = &quot;m64&quot;
TARGET_FPU        = &quot;&quot;
meta              
meta-yocto        
meta-yocto-bsp    = &quot;hongxu-0417-dylan:87eb70243749e0e2431f98770746fa42002f4441&quot;

$make --version
GNU Make 3.82
Built for x86_64-unknown-linux-gnu
Copyright (C) 2010  Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later &lt;http://gnu.org/licenses/gpl.html&gt;
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

$vim conf/local.conf
...
PARALLEL_MAKE = &quot;-j 8&quot;
MACHINE ?= &quot;qemux86-64&quot;
DISTRO_FEATURES_append = &quot; systemd&quot;
VIRTUAL-RUNTIME_init_manager = &quot;systemd&quot;
DISTRO_FEATURES_BACKFILL_CONSIDERED = &quot;sysvinit&quot;
...

*problem
Create a new environment to build systemd, do_compile failed:
...
./x86_64-poky-linux-libtool --mode=execute x86_64-poky-linux-objcopy -O binary -j introspect.Target systemd org.freedesktop.systemd1.Target.xml.tmp &amp;&amp; \
        x86_64-poky-linux-strings org.freedesktop.systemd1.Target.xml.tmp | gawk -f /buildarea2/hongxujia/build-20130417-systemd-exlusive-multilib/tmp/work/x86_64-poky-linux/systemd/1_199-r5/systemd-199/introspect.awk | \
        x86_64-poky-linux-cpp  --sysroot=/buildarea2/hongxujia/build-20130417-systemd-exlusive-multilib/tmp/sysroots/qemux86-64    -m64 -P -O2 -pipe -g -feliminate-unused-debug-types -I/buildarea2/hongxujia/build-20130417-systemd-exlusive-multilib/tmp/sysroots/qemux86-64/usr/include/dbus-1.0 -I/buildarea2/hongxujia/build-20130417-systemd-exlusive-multilib/tmp/sysroots/qemux86-64/usr/lib/dbus-1.0/include   -imacros dbus/dbus-protocol.h -o org.freedesktop.systemd1.Target.xml - &amp;&amp; rm org.freedesktop.systemd1.Target.xml.tmp
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Manager.xml] Error 1
make[2]: *** Waiting for unfinished jobs....
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Job.xml] Error 1
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Unit.xml] Error 1
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Socket.xml] Error 1
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Target.xml] Error 1
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Service.xml] Error 1
x86_64-poky-linux-objcopy: &apos;systemd&apos;: No such file
make[2]: *** [org.freedesktop.systemd1.Timer.xml] Error 1
...

*analysis
1, The error is about parallel make race, see: 
http://savannah.gnu.org/bugs/?30653

2, The system&apos;s make 3.28 didn&apos;t add patch to fix this defect,
but Yocto&apos;s make 3.28 has fixed. See oe-core: 
meta/recipes-devtools/make/make-3.82/intermediate-target-bugfix.patch

*solution
Add `make-native&apos; to systemd&apos;s `DEPENDS&apos; to use Yocto&apos;s make rather
than system&apos;s to compile systemd.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>32614</commentid>
    <comment_count>1</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2013-04-25 09:53:10 +0000</bug_when>
    <thetext>Installing make-native during a build will lead to races over the make binary, causing strange and non-obvious build failures.  3.82 in certain distros is a known issue and we&apos;ll be adding to the release notes that if you have a broken make, run &quot;bitbake make-native&quot; *first*.

That said, 12.1 has the patches required to fix this (https://build.opensuse.org/package/show?package=make&amp;project=openSUSE%3A12.1%3AUpdate, make-parallel-build.patch, added 5 weeks ago) so please update your distro and this will fix itself.

I&apos;m also told that 12.1 will be EOL in 21 days from now, so you should consider upgrading to 12.3.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>