From: Ian Lance Taylor Date: Fri, 27 Oct 1995 00:10:05 +0000 (+0000) Subject: fix output location of common symbols X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1d04caa1f9630dd6d04fc4fa8c1f42826f269f08;p=binutils-gdb.git fix output location of common symbols --- diff --git a/bfd/xcofflink.c b/bfd/xcofflink.c index dda5cd823f2..8dedde0c762 100644 --- a/bfd/xcofflink.c +++ b/bfd/xcofflink.c @@ -3499,7 +3499,10 @@ xcoff_link_input_bfd (finfo, input_bfd) if (! skip && isym.n_sclass == C_EXT && smtyp == XTY_CM - && (*sym_hash)->root.type != bfd_link_hash_common) + && ((*sym_hash)->root.type != bfd_link_hash_common + || (*sym_hash)->root.u.c.p->section != *csectpp) + && ((*sym_hash)->root.type != bfd_link_hash_defined + || (*sym_hash)->root.u.def.section != *csectpp)) skip = true; /* Skip local symbols if we are discarding them. */