diff options
author | Chris Johns <chrisj@rtems.org> | 2019-01-22 08:48:19 +1100 |
---|---|---|
committer | Chris Johns <chrisj@rtems.org> | 2019-02-09 10:06:34 +1100 |
commit | 194eb403c39f5ad346e63dc3352e29570857fd93 (patch) | |
tree | 3ef4976810a6e4545a0d4c68138c270ed3abd22c /cpukit/libdl/rtl-mdreloc-i386.c | |
parent | libdl: Add support for trampolines (diff) | |
download | rtems-194eb403c39f5ad346e63dc3352e29570857fd93.tar.bz2 |
libdl: Add support for large memory programs
- Add trampolines to support relocs that are out of range on
support architectures.
- Support not loading separate text/data sections in an object
file if the symbol provided in the section is a duplicate.
A base image may have pulled in part of an object and another
part needs to be dynamically loaded.
- Refactor the unresolved handling to scale to hundreds of
unresolved symbols when loading large number of files.
Updates #3685
Diffstat (limited to 'cpukit/libdl/rtl-mdreloc-i386.c')
-rw-r--r-- | cpukit/libdl/rtl-mdreloc-i386.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/cpukit/libdl/rtl-mdreloc-i386.c b/cpukit/libdl/rtl-mdreloc-i386.c index 773ef8e916..016f99f379 100644 --- a/cpukit/libdl/rtl-mdreloc-i386.c +++ b/cpukit/libdl/rtl-mdreloc-i386.c @@ -7,6 +7,7 @@ #include <sys/cdefs.h> #include <errno.h> +#include <inttypes.h> #include <stdio.h> #include <sys/types.h> #include <sys/stat.h> @@ -67,7 +68,7 @@ rtems_rtl_elf_relocate_rela (rtems_rtl_obj* obj, const Elf_Word symvalue) { (void) obj; - (void) rela; + (void) rel; (void) sect; (void) symname; (void) syminfo; @@ -147,12 +148,12 @@ rtems_rtl_elf_relocate_rel (rtems_rtl_obj* obj, break; default: - printf ("rtl: reloc unknown: sym = %lu, type = %lu, offset = %p, " + printf ("rtl: reloc unknown: sym = %i, type = %" PRIu32 ", offset = %p, " "contents = %p\n", - ELF_R_SYM(rel->r_info), (uint32_t) ELF_R_TYPE(rel->r_info), + (int) ELF_R_SYM(rel->r_info), (uint32_t) ELF_R_TYPE(rel->r_info), (void *)rel->r_offset, (void *)*where); rtems_rtl_set_error (EINVAL, - "%s: Unsupported relocation type %ld " + "%s: Unsupported relocation type %" PRIu32 " " "in non-PLT relocations", sect->name, (uint32_t) ELF_R_TYPE(rel->r_info)); return false; |