diff options
Diffstat (limited to 'gnu/usr.bin/ld/ld.h')
-rw-r--r-- | gnu/usr.bin/ld/ld.h | 40 |
1 files changed, 27 insertions, 13 deletions
diff --git a/gnu/usr.bin/ld/ld.h b/gnu/usr.bin/ld/ld.h index 58e5c1e..6b4b7f5 100644 --- a/gnu/usr.bin/ld/ld.h +++ b/gnu/usr.bin/ld/ld.h @@ -1,5 +1,5 @@ /* - * $Id: ld.h,v 1.11 1994/06/15 22:39:46 rich Exp $ + * $Id: ld.h,v 1.12 1994/12/23 22:30:42 nate Exp $ */ /*- * This code is derived from software copyrighted by the Free Software @@ -151,6 +151,16 @@ extern int netzmagic; #define CHECK_GOT_RELOC(r) ((r)->r_pcrel) +#define RELOC_INIT_SEGMENT_RELOC(r) + +#endif + +#ifndef MAX_GOTOFF +#define MAX_GOTOFF (LONG_MAX) +#endif + +#ifndef MIN_GOTOFF +#define MIN_GOTOFF (LONG_MIN) #endif /* @@ -309,7 +319,6 @@ extern int netzmagic; #ifndef __GNU_STAB__ - /* Line number for the data section. This is to be used to describe the source location of a variable declaration. */ #ifndef N_DSLINE @@ -321,9 +330,10 @@ extern int netzmagic; #ifndef N_BSLINE #define N_BSLINE (N_SLINE+N_BSS-N_TEXT) #endif - #endif /* not __GNU_STAB__ */ - + +#define N_ISWEAK(p) (N_BIND(p) & BIND_WEAK) + typedef struct localsymbol { struct nzlist nzlist; /* n[z]list from file */ @@ -337,7 +347,7 @@ typedef struct localsymbol { #define LS_L_SYMBOL 1 /* Local symbol starts with an `L' */ #define LS_WRITE 2 /* Symbol goes in output symtable */ #define LS_RENAME 4 /* xlat name to `<file>.<name>' */ -#define LS_GOTSLOTCLAIMED 8 /* This symbol has a GOT entry */ +#define LS_HASGOTSLOT 8 /* This symbol has a GOT entry */ #define LS_WARNING 16 /* Second part of a N_WARNING duo */ } localsymbol_t; @@ -388,14 +398,15 @@ typedef struct glosym { long flags; -#define GS_DEFINED 1 /* Symbol has definition (notyetused)*/ -#define GS_REFERENCED 2 /* Symbol is referred to by something +#define GS_DEFINED 0x1 /* Symbol has definition (notyetused)*/ +#define GS_REFERENCED 0x2 /* Symbol is referred to by something interesting */ -#define GS_TRACE 4 /* Symbol will be traced */ -#define GS_JMPSLOTCLAIMED 8 /* */ -#define GS_GOTSLOTCLAIMED 0x10 /* Some state bits concerning */ +#define GS_TRACE 0x4 /* Symbol will be traced */ +#define GS_HASJMPSLOT 0x8 /* */ +#define GS_HASGOTSLOT 0x10 /* Some state bits concerning */ #define GS_CPYRELOCRESERVED 0x20 /* entries in GOT and PLT tables */ #define GS_CPYRELOCCLAIMED 0x40 /* */ +#define GS_WEAK 0x80 /* Symbol is weakly defined */ } symbol; @@ -415,6 +426,9 @@ extern symbol *symtab[]; /* # of global symbols referenced and not defined. */ extern int undefined_global_sym_count; +/* # of weak symbols referenced and not defined. */ +extern int undefined_weak_sym_count; + /* # of undefined symbols referenced by shared objects */ extern int undefined_shobj_sym_count; @@ -575,7 +589,7 @@ extern int link_mode; #define SHAREABLE 8 /* Build a shared object */ #define SILLYARCHIVE 16 /* Process .sa companions, if any */ -extern int outdesc; /* Output file descriptor. */ +extern FILE *outstream; /* Output file. */ extern struct exec outheader; /* Output file header. */ extern int magic; /* Output file magic. */ extern int oldmagic; @@ -601,8 +615,8 @@ int file_open __P((struct file_entry *)); void each_file __P((void (*)(), void *)); void each_full_file __P((void (*)(), void *)); unsigned long check_each_file __P((unsigned long (*)(), void *)); -void mywrite __P((void *, int, int, int)); -void padfile __P((int,int)); +void mywrite __P((void *, int, int, FILE *)); +void padfile __P((int, FILE *)); /* In warnings.c: */ void perror_name __P((char *)); |