Home | History | Annotate | Line # | Download | only in include
link_elf.h revision 1.9
      1 /*	$NetBSD: link_elf.h,v 1.9 2010/10/14 07:51:21 skrll Exp $	*/
      2 
      3 #ifndef _LINK_ELF_H_
      4 #define	_LINK_ELF_H_
      5 
      6 #include <sys/types.h>
      7 
      8 #include <machine/elf_machdep.h>
      9 
     10 typedef struct link_map {
     11 	caddr_t		 l_addr;	/* Base Address of library */
     12 #ifdef __mips__
     13 	caddr_t		 l_offs;	/* Load Offset of library */
     14 #endif
     15 	const char	*l_name;	/* Absolute Path to Library */
     16 	void		*l_ld;		/* Pointer to .dynamic in memory */
     17 	struct link_map	*l_next;	/* linked list of of mapped libs */
     18 	struct link_map *l_prev;
     19 } Link_map;
     20 
     21 /*
     22  * This only exists for GDB.
     23  */
     24 struct r_debug {
     25 	int r_version;			/* not used */
     26 	struct link_map *r_map;		/* list of loaded images */
     27 	void (*r_brk)(void);		/* pointer to break point */
     28 	enum {
     29 		RT_CONSISTENT,		/* things are stable */
     30 		RT_ADD,			/* adding a shared library */
     31 		RT_DELETE		/* removing a shared library */
     32 	} r_state;
     33 };
     34 
     35 #endif	/* _LINK_ELF_H_ */
     36