yann@98: From http://www.mail-archive.com/pld-cvs-commit@pld-linux.org/msg00229.html yann@98: Fixes yann@98: rtld.c: In function '_dl_start': yann@98: dynamic-link.h:47: error: nested function 'elf_machine_rela_relative' declared but never defined yann@98: dynamic-link.h:41: error: nested function 'elf_machine_rela' declared but never defined yann@98: when compiling glibc-2.3.4 with gcc-4.0 yann@98: yann@98: But see also yann@98: http://sources.redhat.com/ml/libc-hacker/2005-02/msg00000.html yann@98: and yann@98: http://sources.redhat.com/ml/libc-hacker/2005-03/msg00008.html yann@98: which seem to propose less radical fixes? yann@98: yann@98: Aha. See also http://sources.redhat.com/bugzilla/show_bug.cgi?id=721 yann@98: yann@98: --- glibc-2.3.6.orig/elf/dynamic-link.h 2005-03-12 18:12:37.000000000 -0800 yann@98: +++ glibc-2.3.6/elf/dynamic-link.h 2005-03-12 18:12:59.777820848 -0800 yann@98: @@ -19,47 +19,6 @@ yann@98: yann@98: #include yann@98: #include yann@98: - yann@98: -#ifdef RESOLVE_MAP yann@98: -/* We pass reloc_addr as a pointer to void, as opposed to a pointer to yann@98: - ElfW(Addr), because not all architectures can assume that the yann@98: - relocated address is properly aligned, whereas the compiler is yann@98: - entitled to assume that a pointer to a type is properly aligned for yann@98: - the type. Even if we cast the pointer back to some other type with yann@98: - less strict alignment requirements, the compiler might still yann@98: - remember that the pointer was originally more aligned, thereby yann@98: - optimizing away alignment tests or using word instructions for yann@98: - copying memory, breaking the very code written to handle the yann@98: - unaligned cases. */ yann@98: -# if ! ELF_MACHINE_NO_REL yann@98: -auto inline void __attribute__((always_inline)) yann@98: -elf_machine_rel (struct link_map *map, const ElfW(Rel) *reloc, yann@98: - const ElfW(Sym) *sym, const struct r_found_version *version, yann@98: - void *const reloc_addr); yann@98: -auto inline void __attribute__((always_inline)) yann@98: -elf_machine_rel_relative (ElfW(Addr) l_addr, const ElfW(Rel) *reloc, yann@98: - void *const reloc_addr); yann@98: -# endif yann@98: -# if ! ELF_MACHINE_NO_RELA yann@98: -auto inline void __attribute__((always_inline)) yann@98: -elf_machine_rela (struct link_map *map, const ElfW(Rela) *reloc, yann@98: - const ElfW(Sym) *sym, const struct r_found_version *version, yann@98: - void *const reloc_addr); yann@98: -auto inline void __attribute__((always_inline)) yann@98: -elf_machine_rela_relative (ElfW(Addr) l_addr, const ElfW(Rela) *reloc, yann@98: - void *const reloc_addr); yann@98: -# endif yann@98: -# if ELF_MACHINE_NO_RELA || defined ELF_MACHINE_PLT_REL yann@98: -auto inline void __attribute__((always_inline)) yann@98: -elf_machine_lazy_rel (struct link_map *map, yann@98: - ElfW(Addr) l_addr, const ElfW(Rel) *reloc); yann@98: -# else yann@98: -auto inline void __attribute__((always_inline)) yann@98: -elf_machine_lazy_rel (struct link_map *map, yann@98: - ElfW(Addr) l_addr, const ElfW(Rela) *reloc); yann@98: -# endif yann@98: -#endif yann@98: - yann@98: #include yann@98: yann@98: #ifndef VERSYMIDX yann@98: yann@98: Signed-off-by: Robert P. J. Day