summaryrefslogtreecommitdiff
path: root/mld/symtab.c
diff options
context:
space:
mode:
authorFreya Murphy <freya@freyacat.org>2024-10-01 18:20:10 -0400
committerFreya Murphy <freya@freyacat.org>2024-10-01 18:20:10 -0400
commitfb071309905c2911bd696c2cd0eafdae02d1e80b (patch)
treebb931066a32ef069773a17f6e52c1b1d7a919b9b /mld/symtab.c
parentadd nop pseudo code (diff)
downloadmips-fb071309905c2911bd696c2cd0eafdae02d1e80b.tar.gz
mips-fb071309905c2911bd696c2cd0eafdae02d1e80b.tar.bz2
mips-fb071309905c2911bd696c2cd0eafdae02d1e80b.zip
dont require phdr to link
Diffstat (limited to '')
-rw-r--r--mld/symtab.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/mld/symtab.c b/mld/symtab.c
index 9417673..314a1c3 100644
--- a/mld/symtab.c
+++ b/mld/symtab.c
@@ -56,6 +56,10 @@ int symtab_get(struct symbol_table *symtab, Elf32_Sym **res, const char *name,
if (strcmp(name, symname) != 0)
continue;
+ // ignore absolute symbols
+ if (B16(sym->st_shndx) == SHN_ABS)
+ continue;
+
// only allow retrevial of local variables from the
// same object
if (sym->st_info >> 4 != STB_GLOBAL && symtab->map != NULL &&