]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/binutils/binutils-2.14.90.0.7/binutils-undefsym.patch
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / binutils / binutils-2.14.90.0.7 / binutils-undefsym.patch
1   gas/ChangeLog
2   2004-07-01  Nick Clifton  <nickc@redhat.com>
3
4         * config/tc-arm.c (md_apply_fix3:BFD_RELOC_ARM_IMMEDIATE): Do not
5         allow values which have come from undefined symbols.
6         Always consider this fixup to have been processed as a reloc
7         cannot be generated for it.
8
9
10 Index: gas/config/tc-arm.c
11 ===================================================================
12 RCS file: /work/repositories/sourceware/src/gas/config/tc-arm.c,v
13 retrieving revision 1.140.2.1
14 diff -c -3 -p -r1.140.2.1 tc-arm.c
15 *** gas/config/tc-arm.c 13 Jun 2003 16:34:31 -0000      1.140.2.1
16 --- gas/config/tc-arm.c 1 Jul 2004 17:22:43 -0000
17 *************** md_apply_fix3 (fixP, valP, seg)
18 *** 10693,10698 ****
19 --- 10693,10712 ----
20     switch (fixP->fx_r_type)
21       {
22       case BFD_RELOC_ARM_IMMEDIATE:
23 +       /* We claim that this fixup has been processed here,
24 +        even if in fact we generate an error because we do
25 +        not have a reloc for it, so tc_gen_reloc will reject it.  */
26 +       fixP->fx_done = 1;
27
28 +       if (fixP->fx_addsy
29 +         && ! S_IS_DEFINED (fixP->fx_addsy))
30 +       {
31 +         as_bad_where (fixP->fx_file, fixP->fx_line,
32 +                       _("undefined symbol %s used as an immediate value"),
33 +                       S_GET_NAME (fixP->fx_addsy));
34 +         break;
35 +       }
36
37         newimm = validate_immediate (value);
38         temp = md_chars_to_number (buf, INSN_SIZE);
39   
40 *************** md_apply_fix3 (fixP, valP, seg)
41 *** 10709,10715 ****
42   
43         newimm |= (temp & 0xfffff000);
44         md_number_to_chars (buf, (valueT) newimm, INSN_SIZE);
45 -       fixP->fx_done = 1;
46         break;
47   
48       case BFD_RELOC_ARM_ADRL_IMMEDIATE:
49 --- 10723,10728 ----