SYM_SEARCH_SELF|SYM_NOWARNNOTFOUND|SYM_PLT, SYM_NOTPLT, NULL);
SYM_SEARCH_SELF|SYM_NOWARNNOTFOUND|SYM_PLT, 0, NULL);
_dl_md_reloc_got(elf_object_t *object, int lazy){	int	i, n;	Elf32_Addr loff;	Elf32_Addr ooff;	Elf32_Addr *gotp;	const Elf32_Sym  *symp;	const Elf32_Sym  *this;	const char *strt;	Elf_Addr ooff;	const Elf_Sym *this;	if (object->status & STAT_GOT_DONE)		return;	lazy = 0;	/* XXX Fix ld before enabling lazy */	loff = object->load_offs;	strt = object->dyn.strtab;	gotp = object->dyn.pltgot;	n = object->Dyn.info[DT_MIPS_LOCAL_GOTNO - DT_LOPROC + DT_NUM];	/*	 *  Set up pointers for run time (lazy) resolving.	 */	gotp[0] = (int)_dl_rt_resolve;	if (gotp[1] & 0x80000000) {		gotp[1] = (int)object | 0x80000000;	}	/*  First do all local references. */	for (i = ((gotp[1] & 0x80000000) ? 2 : 1); i < n; i++) {		gotp[i] += loff;	}	gotp += n;	symp =  object->dyn.symtab;	symp += object->Dyn.info[DT_MIPS_GOTSYM - DT_LOPROC + DT_NUM];	n =  object->Dyn.info[DT_MIPS_SYMTABNO - DT_LOPROC + DT_NUM] -	    object->Dyn.info[DT_MIPS_GOTSYM - DT_LOPROC + DT_NUM];	this = NULL;	ooff = _dl_find_symbol("__got_start", object, &this,	    SYM_SEARCH_SELF|SYM_NOWARNNOTFOUND|SYM_PLT, SYM_NOTPLT,	    NULL);	if (this != NULL)		object->got_addr = ooff + this->st_value;	this = NULL;	ooff = _dl_find_symbol("__got_end", object, &this,	    SYM_SEARCH_SELF|SYM_NOWARNNOTFOUND|SYM_PLT, SYM_NOTPLT,	    NULL);	if (this != NULL)		object->got_size = ooff + this->st_value  - object->got_addr;	this = NULL;	ooff = _dl_find_symbol("__plt_start", object, &this,	    SYM_SEARCH_SELF|SYM_NOWARNNOTFOUND|SYM_PLT, SYM_NOTPLT,	    NULL);	if (this != NULL)		object->plt_addr = ooff + this->st_value;	this = NULL;	ooff = _dl_find_symbol("__plt_end", object, &this,	    SYM_SEARCH_SELF|SYM_NOWARNNOTFOUND|SYM_PLT, SYM_NOTPLT,	    NULL);	if (this != NULL)		object->plt_size = ooff + this->st_value  - object->plt_addr;	/*	 *  Then do all global references according to the ABI.	 *  Quickstart is not yet implemented.	 */	while (n--) {		if (symp->st_shndx == SHN_UNDEF &&		    ELF32_ST_TYPE(symp->st_info) == STT_FUNC) {DL_DEB(("got: '%s' = %x\n", strt + symp->st_name, symp->st_value));			if (symp->st_value == 0 || !lazy) {				this = 0;				ooff = _dl_find_symbol(strt + symp->st_name,				    _dl_objects, &this,				    SYM_SEARCH_ALL|SYM_NOWARNNOTFOUND|SYM_PLT,				    symp->st_size, object->load_name);				if (this)					*gotp = this->st_value + ooff;			} else				*gotp = symp->st_value + ooff;		} else if (symp->st_shndx == SHN_COMMON ||			symp->st_shndx == SHN_UNDEF) {			this = 0;			ooff = _dl_find_symbol(strt + symp->st_name,			    _dl_objects, &this,			    SYM_SEARCH_ALL|SYM_NOWARNNOTFOUND|SYM_PLT,			    symp->st_size, object->load_name);			if (this)				*gotp = this->st_value + ooff;		} else if (ELF32_ST_TYPE(symp->st_info) == STT_FUNC) {			*gotp += loff;		} else {	/* XXX ??? */	/* Resolve all others immediatly */			*gotp = symp->st_value + loff;		}		gotp++;		symp++;	}	object->status |= STAT_GOT_DONE;	if (object->got_addr != NULL && object->got_size != 0)		_dl_mprotect((void*)object->got_addr, object->got_size,		    PROT_READ);	if (object->plt_addr != NULL && object->plt_size != 0)		_dl_mprotect((void*)object->plt_addr, object->plt_size,		    PROT_READ|PROT_EXEC);}