aboutsummaryrefslogtreecommitdiff
path: root/bfd/elflink.h
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>2000-02-22 05:51:02 +0000
committerIan Lance Taylor <ian@airs.com>2000-02-22 05:51:02 +0000
commit2bd171e0011e5577b841a53468b7467fc7f6eaae (patch)
treeb33bc852d709e1f328e95266539c103de0a2bc42 /bfd/elflink.h
parent8883511eb0dbbe065ff1a8c33f1b45dbd6f2800a (diff)
downloadfsf-binutils-gdb-2bd171e0011e5577b841a53468b7467fc7f6eaae.zip
fsf-binutils-gdb-2bd171e0011e5577b841a53468b7467fc7f6eaae.tar.gz
fsf-binutils-gdb-2bd171e0011e5577b841a53468b7467fc7f6eaae.tar.bz2
2000-02-22 H.J. Lu <hjl@gnu.org>
* elflink.h (elf_bfd_final_link): Call output_extsym for global symbols converted to local symbols even when stripping all symbols. (elf_link_output_extsym): Process global symbols converted to local symbols even if they are being stripped.
Diffstat (limited to 'bfd/elflink.h')
-rw-r--r--bfd/elflink.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/bfd/elflink.h b/bfd/elflink.h
index 54577a6..00037b3 100644
--- a/bfd/elflink.h
+++ b/bfd/elflink.h
@@ -1,5 +1,5 @@
/* ELF linker support.
- Copyright 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -4393,7 +4393,7 @@ elf_bfd_final_link (abfd, info)
/* That wrote out all the local symbols. Finish up the symbol table
with the global symbols. */
- if (info->strip != strip_all && info->shared)
+ if (info->shared)
{
/* Output any global symbols that got converted to local in a
version script. We do this in a separate step since ELF
@@ -4928,8 +4928,10 @@ elf_link_output_extsym (h, data)
strip = false;
/* If we're stripping it, and it's not a dynamic symbol, there's
- nothing else to do. */
- if (strip && h->dynindx == -1)
+ nothing else to do unless it is a forced local symbol. */
+ if (strip
+ && h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
return true;
sym.st_value = 0;