* write.c (fixup_segment) [TC_DONT_FIX_NON_ADJUSTABLE]: Use

obj_fix_adjustable() and tc_fix_adjustable() to tell whether to
add a symbol's address.  Removed all target-specific #ifdefs that
used to accomplished the same.
* config/tc-v850.h (TC_DONT_FIX_NON_ADJUSTABLE): Define.
* config/tc-m68k.h (TC_DONT_FIX_NON_ADJUSTABLE): Define.
* config/tc-arm.h (TC_DONT_FIX_NON_ADJUSTABLE): Define.
* config/tc-i960.h (TC_DONT_FIX_NON_ADJUSTABLE): Define.
* config/tc-i386.h (TC_DONT_FIX_NON_ADJUSTABLE): Define.
This commit is contained in:
Alexandre Oliva
2000-08-18 18:45:05 +00:00
parent 2ac374c471
commit 021986386e
7 changed files with 41 additions and 9 deletions

View File

@@ -2706,17 +2706,17 @@ fixup_segment (fixP, this_segment_type)
else
{
seg_reloc_count++;
#if !(defined (TC_V850) && defined (OBJ_ELF))
#if !(defined (TC_M68K) && defined (OBJ_ELF))
#if !(defined (TC_ARM) && defined (OBJ_ELF))
#if !(defined (TC_I960) && defined (OBJ_ELF))
#if !defined (TC_I386) || !(defined (OBJ_ELF) || defined (OBJ_COFF)) || defined (TE_PE)
add_number += S_GET_VALUE (add_symbolP);
#endif
#endif
#ifdef TC_DONT_FIX_NON_ADJUSTABLE
if (1
#ifdef obj_fix_adjustable
&& obj_fix_adjustable (fixP)
#endif
#ifdef tc_fix_adjustable
&& tc_fix_adjustable (fixP)
#endif
)
#endif
add_number += S_GET_VALUE (add_symbolP);
}
}
}