diff options
author | Ian Lance Taylor <ian@airs.com> | 1994-06-16 00:01:32 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 1994-06-16 00:01:32 +0000 |
commit | c1f84521bf0f5f12617ac204d78b5b9b4c72a8b9 (patch) | |
tree | 3805856c968ac3fce3ba35bd30ab60a9d5738a21 /bfd/elfcode.h | |
parent | 33b90e52657a579d9c613db8ac06e5c604e34818 (diff) | |
download | gdb-c1f84521bf0f5f12617ac204d78b5b9b4c72a8b9.zip gdb-c1f84521bf0f5f12617ac204d78b5b9b4c72a8b9.tar.gz gdb-c1f84521bf0f5f12617ac204d78b5b9b4c72a8b9.tar.bz2 |
* libelf.h (struct elf_obj_tdata): New field dt_needed_name.
(elf_dt_needed_name): New accessor macro.
* elfcode.h (elf_link_add_object_symbols): If elf_dt_needed_name
is set, use that instead of the filename for the DT_NEEDED dynamic
entry.
* elf.c (bfd_elf_set_dt_needed_name): New function.
* bfd-in.h (bfd_elf_set_dt_needed_name): Declare.
* bfd-in2.h: Rebuilt.
Diffstat (limited to 'bfd/elfcode.h')
-rw-r--r-- | bfd/elfcode.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/bfd/elfcode.h b/bfd/elfcode.h index c46ffde..e471b56 100644 --- a/bfd/elfcode.h +++ b/bfd/elfcode.h @@ -4163,8 +4163,12 @@ elf_link_add_object_symbols (abfd, info) /* Find the name to use in a DT_NEEDED entry that refers to this object. If the object has a DT_SONAME entry, we use it. - Otherwise, we use the file name. */ + Otherwise, if the generic linker stuck something in + elf_dt_needed_name, we use that. Otherwise, we just use the + file name. */ name = bfd_get_filename (abfd); + if (elf_dt_needed_name (abfd) != NULL) + name = elf_dt_needed_name (abfd); s = bfd_get_section_by_name (abfd, ".dynamic"); if (s != NULL) { |