<div><div dir="auto">What&#39;s the link to upstream bug in linker </div><br><div class="gmail_quote"><div>On Thu, Jun 22, 2017 at 12:34 AM Randy MacLeod &lt;<a href="mailto:randy.macleod@windriver.com">randy.macleod@windriver.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Merge if you like or wait for the real fix to binutils.<br>
<br>
This bug has been around for more than a week<br>
since the binutils upgrade was merged and<br>
no one else seems to have noticed so it doesn&#39;t<br>
seem urgent.<br>
<br>
I needed the work-around to keep our auto-builders happy.<br>
Oh and I did basic sanity testing to show that booting<br>
and systemctl status works on qemuppc.<br>
<br>
../Randy<br>
<br>
On 2017-06-21 10:14 PM, Randy MacLeod wrote:<br>
&gt; If you enable systemd and build for qemuppc, then the<br>
&gt; compile of systemd fails due to a gold linker failure:<br>
&gt;<br>
&gt;     .../powerpc-oe-linux-ld.gold:<br>
&gt;     error: invalid STB_LOCAL symbol in external symbols<br>
&gt;     error: linker defined: multiple definition of &#39;00000001.plt_call.memcpy+8000&#39;<br>
&gt;     command line: previous definition here<br>
&gt;<br>
&gt; A git bisect confirms that the commit:<br>
&gt;     0b0f545 binutils-2.28: Update to latest on release branch<br>
&gt; is the problem. This is only known to affect powerpc machines.<br>
&gt;<br>
&gt; Work-around this for powerpc by getting configure to use<br>
&gt; the bfd linker rather than the gold linker.<br>
&gt;<br>
&gt; This unblocks powerpc use until the linker bug can be resolved.<br>
&gt;<br>
&gt; Signed-off-by: Randy MacLeod &lt;<a href="mailto:Randy.MacLeod@windriver.com" target="_blank">Randy.MacLeod@windriver.com</a>&gt;<br>
&gt; ---<br>
&gt;   .../systemd/systemd/systemd-drop-gold-use-bfd.patch   | 19 +++++++++++++++++++<br>
&gt;   meta/recipes-core/systemd/<a href="http://systemd_232.bb" rel="noreferrer" target="_blank">systemd_232.bb</a>              |  2 ++<br>
&gt;   2 files changed, 21 insertions(+)<br>
&gt;   create mode 100644 meta/recipes-core/systemd/systemd/systemd-drop-gold-use-bfd.patch<br>
&gt;<br>
&gt; diff --git a/meta/recipes-core/systemd/systemd/systemd-drop-gold-use-bfd.patch b/meta/recipes-core/systemd/systemd/systemd-drop-gold-use-bfd.patch<br>
&gt; new file mode 100644<br>
&gt; index 0000000..e0eb0bd<br>
&gt; --- /dev/null<br>
&gt; +++ b/meta/recipes-core/systemd/systemd/systemd-drop-gold-use-bfd.patch<br>
&gt; @@ -0,0 +1,19 @@<br>
&gt; +Upstream-Status: Inappropriate [other]<br>
&gt; +<br>
&gt; +The patch is not appropriate for upstream since it&#39;s a temporary<br>
&gt; +work-around for only ppc arches. Once the binutils defect in the<br>
&gt; +gold linker is resolved, this patch can be dropped.<br>
&gt; +<br>
&gt; +Signed-off-by: Randy MacLeod &lt;<a href="mailto:Randy.MacLeod@windriver.com" target="_blank">Randy.MacLeod@windriver.com</a>&gt;<br>
&gt; +<br>
&gt; +--- a/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
&gt; ++++ b/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
&gt; +@@ -260,7 +260,7 @@<br>
&gt; +         -Wl,-z,relro \<br>
&gt; +         -Wl,-z,now \<br>
&gt; +         -pie \<br>
&gt; +-        -Wl,-fuse-ld=gold])<br>
&gt; ++        -Wl,-fuse-ld=bfd])<br>
&gt; + AC_SUBST([OUR_LDFLAGS], &quot;$with_ldflags $sanitizer_ldflags&quot;)<br>
&gt; +<br>
&gt; + AC_CHECK_SIZEOF(pid_t)<br>
&gt; diff --git a/meta/recipes-core/systemd/<a href="http://systemd_232.bb" rel="noreferrer" target="_blank">systemd_232.bb</a> b/meta/recipes-core/systemd/<a href="http://systemd_232.bb" rel="noreferrer" target="_blank">systemd_232.bb</a><br>
&gt; index 1007360..1e8dffe 100644<br>
&gt; --- a/meta/recipes-core/systemd/<a href="http://systemd_232.bb" rel="noreferrer" target="_blank">systemd_232.bb</a><br>
&gt; +++ b/meta/recipes-core/systemd/<a href="http://systemd_232.bb" rel="noreferrer" target="_blank">systemd_232.bb</a><br>
&gt; @@ -41,6 +41,8 @@ SRC_URI_append_libc-uclibc = &quot;\<br>
&gt;   &quot;<br>
&gt;   SRC_URI_append_qemuall = &quot; file://0001-core-device.c-Change-the-default-device-timeout-to-2.patch&quot;<br>
&gt;<br>
&gt; +SRC_URI_append_powerpc = &quot; file://systemd-drop-gold-use-bfd.patch&quot;<br>
&gt; +<br>
&gt;   PACKAGECONFIG ??= &quot;xz \<br>
&gt;                      ${@bb.utils.filter(&#39;DISTRO_FEATURES&#39;, &#39;efi pam selinux ldconfig&#39;, d)} \<br>
&gt;                      ${@bb.utils.contains(&#39;DISTRO_FEATURES&#39;, &#39;x11&#39;, &#39;xkbcommon&#39;, &#39;&#39;, d)} \<br>
&gt;<br>
<br>
<br>
--<br>
# Randy MacLeod. SMTS, Linux, Wind River<br>
Direct: 613.963.1350 | 350 Terry Fox Drive, Suite 200, Ottawa, ON,<br>
Canada, K2K 2W5<br>
--<br>
_______________________________________________<br>
Openembedded-core mailing list<br>
<a href="mailto:Openembedded-core@lists.openembedded.org" target="_blank">Openembedded-core@lists.openembedded.org</a><br>
<a href="http://lists.openembedded.org/mailman/listinfo/openembedded-core" rel="noreferrer" target="_blank">http://lists.openembedded.org/mailman/listinfo/openembedded-core</a><br>
</blockquote></div></div>