Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/include/link_elf.h,v rcsdiff: /ftp/cvs/cvsroot/src/include/link_elf.h,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.9 retrieving revision 1.10 diff -u -p -r1.9 -r1.10 --- src/include/link_elf.h 2010/10/14 07:51:21 1.9 +++ src/include/link_elf.h 2010/10/16 10:27:06 1.10 @@ -1,11 +1,10 @@ -/* $NetBSD: link_elf.h,v 1.9 2010/10/14 07:51:21 skrll Exp $ */ +/* $NetBSD: link_elf.h,v 1.10 2010/10/16 10:27:06 skrll Exp $ */ #ifndef _LINK_ELF_H_ #define _LINK_ELF_H_ #include - -#include +#include typedef struct link_map { caddr_t l_addr; /* Base Address of library */ @@ -32,4 +31,23 @@ struct r_debug { } r_state; }; +struct dl_phdr_info +{ + Elf_Addr dlpi_addr; /* module relocation base */ + const char *dlpi_name; /* module name */ + const Elf_Phdr *dlpi_phdr; /* pointer to module's phdr */ + Elf_Half dlpi_phnum; /* number of entries in phdr */ + unsigned long long int dlpi_adds; /* total # of loads */ + unsigned long long int dlpi_subs; /* total # of unloads */ + size_t dlpi_tls_modid; + void *dlpi_tls_data; +}; + +__BEGIN_DECLS + +int dl_iterate_phdr(int (*)(struct dl_phdr_info *, size_t, void *), + void *); + +__END_DECLS + #endif /* _LINK_ELF_H_ */