From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark Klein To: Ian Lance Taylor Cc: binutils@sourceware.cygnus.com Subject: Re: HPPA/SOM Patch Date: Thu, 01 Jul 1999 00:00:00 -0000 Message-id: <4.1.19990604120444.00bb4210@garfield.dis.com> References: <4.1.19990604110845.00bb5100@garfield.dis.com> <199906041738.KAA23662@dis.dis.com> <199906041738.KAA23662@dis.dis.com> <4.1.19990604110845.00bb5100@garfield.dis.com> <19990604182232.8616.qmail@daffy.airs.com> X-SW-Source: 1999-q2/msg00135.html At 02:22 PM 6/4/99 -0400, Ian Lance Taylor wrote: >Is it true that set_symtab is called before the error occurs? Yes. >If so, why is hppa_fix_adjustable being called after set_symtab? It is part of my earlier fix. There are certain fixups that don't have a symbol associated with them. In that case, the original code referenced a dummy symbol. I changed that to the symbol_get_bfdsym() call below. *** 2886,2892 **** case R_ENTRY: case R_EXIT: /* There is no symbol associated with these fixups. */ ! relocs[i]->sym_ptr_ptr = &dummy_symbol->bsym; relocs[i]->addend = fixp->fx_offset; break; --- 2893,2900 ---- case R_ENTRY: case R_EXIT: /* There is no symbol associated with these fixups. */ ! relocs[i]->sym_ptr_ptr = (asymbol **) xmalloc (sizeof (asymbol *)); ! *relocs[i]->sym_ptr_ptr = symbol_get_bfdsym (dummy_symbol); relocs[i]->addend = fixp->fx_offset; break; That in turn is causing tc_gen_reloc() to be invoked within write_relocs() and voila! So, did I make a wrong assumption here, or should set_symtab be delayed until after the bfd_map_over_sections (stdoutput, write_relocs, (char *) 0) ? Regards, M. -- Mark Klein DIS International, Ltd. http://www.dis.com 415-892-8400 PGP Public Key Available --