/* coff object file format
- Copyright (C) 1989, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 2000
+ Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001
Free Software Foundation, Inc.
This file is part of GAS.
char *name;
int c;
symbolS *symbolP;
-
+
do
{
name = input_line_pointer;
*input_line_pointer = c;
SKIP_WHITESPACE ();
-#ifdef BFD_ASSEMBLER
+#if defined BFD_ASSEMBLER || defined S_SET_WEAK
S_SET_WEAK (symbolP);
#endif
static void SA_SET_SYM_TAGNDX PARAMS ((symbolS *, symbolS *));
#define GET_FILENAME_STRING(X) \
-((char*)(&((X)->sy_symbol.ost_auxent->x_file.x_n.x_offset))[1])
+((char*) (&((X)->sy_symbol.ost_auxent->x_file.x_n.x_offset))[1])
/* @@ Ick. */
static segT
return val;
}
-/* Merge a debug symbol containing debug information into a normal symbol. */
+/* Merge a debug symbol containing debug information into a normal symbol. */
void
c_symbol_merge (debug, normal)
* sizeof (*SYM_AUXINFO (debug))));
}
- /* Move the debug flags. */
+ /* Move the debug flags. */
SF_SET_DEBUG_FIELD (normal, SF_GET_DEBUG_FIELD (debug));
}
{
long sz = (OBJ_COFF_MAX_AUXENTRIES + 1) * sizeof (combined_entry_type);
char * s = (char *) xmalloc (sz);
-
+
memset (s, 0, sz);
coffsymbol (symbol_get_bfdsym (symbolP))->native = (combined_entry_type *) s;
if (S_IS_STRING (symbolP))
SF_SET_STRING (symbolP);
-
+
if (S_IS_LOCAL (symbolP))
SF_SET_LOCAL (symbolP);
}
{
abort ();
}
- if (num <= 0)
+ if (num <= 0)
{
/* Zero is used as an end marker in the file. */
as_warn (_("Line numbers must be positive integers\n"));
return;
} /* if not inside .def/.endef */
- /* Set the section number according to storage class. */
+ /* Set the section number according to storage class. */
switch (S_GET_STORAGE_CLASS (def_symbol_in_progress))
{
case C_STRTAG:
break;
case C_EFCN:
- SF_SET_LOCAL (def_symbol_in_progress); /* Do not emit this symbol. */
+ SF_SET_LOCAL (def_symbol_in_progress); /* Do not emit this symbol. */
/* intentional fallthrough */
case C_BLOCK:
SF_SET_PROCESS (def_symbol_in_progress); /* Will need processing before writing */
{
switch (name[1])
{
- case 'b':
+ case 'b':
/* .bf */
if (! in_function ())
as_warn (_("`%s' symbol without preceding function"), name);
clear_function ();
break;
#ifdef TE_PE
- case 'e':
+ case 'e':
/* .ef */
/* The MS compilers output the actual endline, not the
function-relative one... we want to match without
changing the assembler input. */
- SA_SET_SYM_LNNO (def_symbol_in_progress,
+ SA_SET_SYM_LNNO (def_symbol_in_progress,
(SA_GET_SYM_LNNO (def_symbol_in_progress)
+ coff_line_base));
break;
case C_ARG:
case C_REGPARM:
case C_FIELD:
+
+ /* According to the COFF documentation:
+
+ http://osr5doc.sco.com:1996/topics/COFF_SectNumFld.html
+
+ A special section number (-2) marks symbolic debugging symbols,
+ including structure/union/enumeration tag names, typedefs, and
+ the name of the file. A section number of -1 indicates that the
+ symbol has a value but is not relocatable. Examples of
+ absolute-valued symbols include automatic and register variables,
+ function arguments, and .eos symbols.
+
+ But from Ian Lance Taylor:
+
+ http://sources.redhat.com/ml/binutils/2000-08/msg00202.html
+
+ the actual tools all marked them as section -1. So the GNU COFF
+ assembler follows historical COFF assemblers.
+
+ However, it causes problems for djgpp
+
+ http://sources.redhat.com/ml/binutils/2000-08/msg00210.html
+
+ By defining STRICTCOFF, a COFF port can make the assembler to
+ follow the documented behavior. */
+#ifdef STRICTCOFF
+ case C_MOS:
+ case C_MOE:
+ case C_MOU:
+ case C_EOS:
+#endif
SF_SET_DEBUG (def_symbol_in_progress);
S_SET_SEGMENT (def_symbol_in_progress, absolute_section);
break;
+#ifndef STRICTCOFF
case C_MOS:
case C_MOE:
case C_MOU:
case C_EOS:
S_SET_SEGMENT (def_symbol_in_progress, absolute_section);
break;
+#endif
case C_EXT:
case C_WEAKEXT:
lineno entry MUST point to the definition function or else it
will point off into space when obj_crawl_symbol_chain() merges
the debug symbol into the real symbol. Therefor, let's presume
- the debug symbol is a real function reference. */
+ the debug symbol is a real function reference. */
/* FIXME-SOON If for some reason the definition label/symbol is
never seen, this will probably leave an undefined symbol at link
- time. */
+ time. */
if (S_GET_STORAGE_CLASS (def_symbol_in_progress) == C_EFCN
|| S_GET_STORAGE_CLASS (def_symbol_in_progress) == C_LABEL
symbols. [loic] */
/* The debug entry (def_symbol_in_progress) is merged into the
- previous definition. */
+ previous definition. */
c_symbol_merge (def_symbol_in_progress, symbolP);
symbol_remove (def_symbol_in_progress, &symbol_rootP, &symbol_lastP);
{
/* For functions, and tags, and static symbols, the symbol
*must* be where the debug symbol appears. Move the
- existing symbol to the current place. */
+ existing symbol to the current place. */
/* If it already is at the end of the symbol list, do nothing */
if (def_symbol_in_progress != symbol_lastP)
{
if (symbolP == NULL)
{
/* That is, if this is the first time we've seen the
- function... */
+ function... */
symbol_table_insert (def_symbol_in_progress);
} /* definition follows debug */
} /* Create the line number entry pointing to the function being defined */
#endif
/* Assume that the symbol referred to by .tag is always defined.
- This was a bad assumption. I've added find_or_make. xoxorich. */
+ This was a bad assumption. I've added find_or_make. xoxorich. */
SA_SET_SYM_TAGNDX (def_symbol_in_progress,
tag_find_or_make (symbol_name));
if (SA_GET_SYM_TAGNDX (def_symbol_in_progress) == 0L)
just below. */
}
/* Otherwise, it is the name of a non debug symbol and its value
- will be calculated later. */
+ will be calculated later. */
*input_line_pointer = name_end;
}
else
void
coff_obj_read_begin_hook ()
{
- /* These had better be the same. Usually 18 bytes. */
+ /* These had better be the same. Usually 18 bytes. */
#ifndef BFD_HEADERS
know (sizeof (SYMENT) == sizeof (AUXENT));
know (SYMESZ == AUXESZ);
tag_init ();
}
-
symbolS *coff_last_function;
static symbolS *coff_last_bf;
if (SF_GET_FUNCTION (symp))
symbol_get_bfdsym (symp)->flags |= BSF_FUNCTION;
- /* more ... */
+ /* more ... */
}
/* Double check weak symbols. */
switch (*input_line_pointer)
{
case 'b': flags |= SEC_ALLOC; flags &=~ SEC_LOAD; break;
- case 'n': flags &=~ SEC_LOAD; break;
+ case 'n': flags &=~ SEC_LOAD; flags |= SEC_NEVER_LOAD; break;
case 'd': flags |= SEC_DATA | SEC_LOAD; /* fall through */
case 'w': flags &=~ SEC_READONLY; break;
case 'x': flags |= SEC_CODE | SEC_LOAD; break;
Provide a default if no flags were parsed. */
if (flags == SEC_NO_FLAGS)
flags = TC_COFF_SECTION_DEFAULT_ATTRIBUTES;
-
+
#ifdef COFF_LONG_SECTION_NAMES
/* Add SEC_LINK_ONCE and SEC_LINK_DUPLICATES_DISCARD to .gnu.linkonce
sections so adjust_reloc_syms in write.c will correctly handle
relocs which refer to non-local symbols in these sections. */
- if (strncmp (name, ".gnu.linkonce", sizeof(".gnu.linkonce") - 1) == 0)
+ if (strncmp (name, ".gnu.linkonce", sizeof (".gnu.linkonce") - 1) == 0)
flags |= SEC_LINK_ONCE | SEC_LINK_DUPLICATES_DISCARD;
#endif
/* This section's attributes have already been set. Warn if the
attributes don't match. */
flagword matchflags = SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_CODE
- | SEC_DATA | SEC_SHARED;
+ | SEC_DATA | SEC_SHARED | SEC_NEVER_LOAD;
if ((flags ^ oldflags) & matchflags)
as_warn (_("Ignoring changed section attributes for %s"), name);
}
rounded up to multiples of the corresponding section alignments,
supposedly because standard COFF has no other way of encoding alignment
for sections. If your COFF flavor has a different way of encoding
- section alignment, then skip this step, as TICOFF does. */
+ section alignment, then skip this step, as TICOFF does. */
size = bfd_get_section_size_before_reloc (sec);
mask = ((bfd_vma) 1 << align_power) - 1;
#if !defined(TICOFF)
{
bfd_vma new_size;
fragS *last;
-
+
new_size = (size + mask) & ~mask;
bfd_set_section_size (stdoutput, sec, new_size);
char *stabstr_name;
unsigned int stroff;
- /* Make space for this first symbol. */
+ /* Make space for this first symbol. */
p = frag_more (12);
- /* Zero it out. */
+ /* Zero it out. */
memset (p, 0, 12);
as_where (&file, (unsigned int *) NULL);
stabstr_name = (char *) alloca (strlen (seg->name) + 4);
for (symbolP = symbol_rootP; symbolP; symbolP = symbol_next (symbolP))
{
- printf(_("0x%lx: \"%s\" type = %ld, class = %d, segment = %d\n"),
+ printf (_("0x%lx: \"%s\" type = %ld, class = %d, segment = %d\n"),
(unsigned long) symbolP,
S_GET_NAME(symbolP),
(long) S_GET_DATA_TYPE(symbolP),
#else /* not BFD_ASSEMBLER */
#include "frags.h"
-/* This is needed because we include internal bfd things. */
+/* This is needed because we include internal bfd things. */
#include <time.h>
#include "libbfd.h"
/* structure used to keep the filenames which
are too long around so that we can stick them
into the string table */
-struct filename_list
+struct filename_list
{
char *filename;
struct filename_list *next;
static void fixup_segment PARAMS ((segment_info_type *segP,
segT this_segment_type));
-
static void fixup_mdeps PARAMS ((fragS *,
object_headers *,
segT));
-
static void fill_section PARAMS ((bfd * abfd,
object_headers *,
unsigned long *));
-
static int c_line_new PARAMS ((symbolS * symbol, long paddr,
int line_number,
fragS * frag));
-
static void w_symbols PARAMS ((bfd * abfd, char *where,
symbolS * symbol_rootP));
return (new_address - address);
}
-
segT
s_get_segment (x)
symbolS * x;
break;
case rs_align:
case rs_align_code:
+ case rs_align_test:
{
addressT off;
return size;
}
-
static unsigned int
count_entries_in_chain (idx)
unsigned int idx;
H_SET_RELOCATION_SIZE (h, *file_cursor - reloc_start, 0);
}
-
/* run through a frag chain and write out the data to go with it, fill
in the scnhdrs with the info on the file postions
*/
case rs_fill:
case rs_align:
case rs_align_code:
+ case rs_align_test:
case rs_org:
if (frag->fr_fix)
{
}
}
-
char *
symbol_to_chars (abfd, where, symbolP)
bfd * abfd;
char underscore = 0; /* Symbol has leading _ */
/* Effective symbol */
- /* Store the pointer in the offset. */
+ /* Store the pointer in the offset. */
S_SET_ZEROES (symbolP, 0L);
S_SET_DATA_TYPE (symbolP, T_NULL);
S_SET_STORAGE_CLASS (symbolP, 0);
unsigned int dim_index;
-
static void
obj_coff_endef (ignore)
int ignore ATTRIBUTE_UNUSED;
return;
} /* if not inside .def/.endef */
- /* Set the section number according to storage class. */
+ /* Set the section number according to storage class. */
switch (S_GET_STORAGE_CLASS (def_symbol_in_progress))
{
case C_STRTAG:
break;
case C_EFCN:
- SF_SET_LOCAL (def_symbol_in_progress); /* Do not emit this symbol. */
+ SF_SET_LOCAL (def_symbol_in_progress); /* Do not emit this symbol. */
/* intentional fallthrough */
case C_BLOCK:
SF_SET_PROCESS (def_symbol_in_progress); /* Will need processing before writing */
SF_SET_PROCESS (def_symbol_in_progress);
function_lineoff = -1;
}
- /* Value is always set to . */
+ /* Value is always set to . */
def_symbol_in_progress->sy_frag = frag_now;
S_SET_VALUE (def_symbol_in_progress, (valueT) frag_now_fix ());
break;
lineno entry MUST point to the definition function or else it
will point off into space when crawl_symbols() merges the debug
symbol into the real symbol. Therefor, let's presume the debug
- symbol is a real function reference. */
+ symbol is a real function reference. */
/* FIXME-SOON If for some reason the definition label/symbol is
never seen, this will probably leave an undefined symbol at link
- time. */
+ time. */
if (S_GET_STORAGE_CLASS (def_symbol_in_progress) == C_EFCN
|| S_GET_STORAGE_CLASS (def_symbol_in_progress) == C_LABEL
previous definition. */
c_symbol_merge (def_symbol_in_progress, symbolP);
- /* FIXME-SOON Should *def_symbol_in_progress be free'd? xoxorich. */
+ /* FIXME-SOON Should *def_symbol_in_progress be free'd? xoxorich. */
def_symbol_in_progress = symbolP;
if (SF_GET_FUNCTION (def_symbol_in_progress)
{
/* For functions, and tags, and static symbols, the symbol
*must* be where the debug symbol appears. Move the
- existing symbol to the current place. */
+ existing symbol to the current place. */
/* If it already is at the end of the symbol list, do nothing */
if (def_symbol_in_progress != symbol_lastP)
{
if (symbolP == NULL)
{
/* That is, if this is the first time we've seen the
- function... */
+ function... */
symbol_table_insert (def_symbol_in_progress);
} /* definition follows debug */
} /* Create the line number entry pointing to the function being defined */
#endif
/* Assume that the symbol referred to by .tag is always defined.
- This was a bad assumption. I've added find_or_make. xoxorich. */
+ This was a bad assumption. I've added find_or_make. xoxorich. */
SA_SET_SYM_TAGNDX (def_symbol_in_progress,
(long) tag_find_or_make (symbol_name));
if (SA_GET_SYM_TAGNDX (def_symbol_in_progress) == 0L)
just below. */
}
/* Otherwise, it is the name of a non debug symbol and
- its value will be calculated later. */
+ its value will be calculated later. */
*input_line_pointer = name_end;
/* FIXME: this is to avoid an error message in the
void
coff_obj_read_begin_hook ()
{
- /* These had better be the same. Usually 18 bytes. */
+ /* These had better be the same. Usually 18 bytes. */
#ifndef BFD_HEADERS
know (sizeof (SYMENT) == sizeof (AUXENT));
know (SYMESZ == AUXESZ);
/* Debug symbols do not need all this rubbish */
symbolS *real_symbolP;
- /* L* and C_EFCN symbols never merge. */
+ /* L* and C_EFCN symbols never merge. */
if (!SF_GET_LOCAL (symbolP)
&& !SF_GET_STATICS (symbolP)
&& S_GET_STORAGE_CLASS (symbolP) != C_LABEL
&& real_symbolP != symbolP)
{
/* FIXME-SOON: where do dups come from?
- Maybe tag references before definitions? xoxorich. */
+ Maybe tag references before definitions? xoxorich. */
/* Move the debug data from the debug symbol to the
real symbol. Do NOT do the oposite (i.e. move from
real symbol to debug symbol and remove real symbol from the
list.) Because some pointers refer to the real symbol
- whereas no pointers refer to the debug symbol. */
+ whereas no pointers refer to the debug symbol. */
c_symbol_merge (symbolP, real_symbolP);
/* Replace the current symbol by the real one */
/* The symbols will never be the last or the first
/* Mainly to speed up if not -g */
if (SF_GET_PROCESS (symbolP))
{
- /* Handle the nested blocks auxiliary info. */
+ /* Handle the nested blocks auxiliary info. */
if (S_GET_STORAGE_CLASS (symbolP) == C_BLOCK)
{
if (!strcmp (S_GET_NAME (symbolP), ".bb"))
/* If we are able to identify the type of a function, and we
are out of a function (last_functionP == 0) then, the
function symbol will be associated with an auxiliary
- entry. */
+ entry. */
if (last_functionP == (symbolS *) 0 &&
SF_GET_FUNCTION (symbolP))
{
S_SET_NUMBER_AUXILIARY (symbolP, 1);
} /* make it at least 1 */
- /* Clobber possible stale .dim information. */
+ /* Clobber possible stale .dim information. */
#if 0
/* Iffed out by steve - this fries the lnnoptr info too */
bzero (symbolP->sy_symbol.ost_auxent[0].x_sym.x_fcnary.x_ary.x_dimen,
else if (SF_GET_TAG (symbolP))
{
/* First descriptor of a structure must point to
- the first slot after the structure description. */
+ the first slot after the structure description. */
last_tagP = symbolP;
}
[21] foo external
[22] .be
ld will move the symbol 21 to the end of the list but
- endndx will still be 22 instead of 21. */
-
+ endndx will still be 22 instead of 21. */
if (SF_GET_LOCAL (symbolP))
{
}
-
static unsigned int
glue_symbols (head, tail)
symbolS **head;
* undefined symbols at the end of the list.
*/
- /* Is there a .file symbol ? If not insert one at the beginning. */
+ /* Is there a .file symbol ? If not insert one at the beginning. */
if (symbol_rootP == NULL
|| S_GET_STORAGE_CLASS (symbol_rootP) != C_FILE)
{
* Build up static symbols for the sections, they are filled in later
*/
-
for (i = SEG_E0; i < SEG_LAST; i++)
if (segment_info[i].scnhdr.s_name[0])
segment_info[i].dot = c_section_symbol (segment_info[i].name,
{
segment_info_type *s = segment_info + idx;
-
if (s->scnhdr.s_nlnno != 0)
{
struct lineno_list *line_ptr;
line_ptr->line.l_addr.l_paddr += ((struct frag *) (line_ptr->frag))->fr_address;
}
-
(void) bfd_coff_swap_lineno_out (abfd, &(line_ptr->line), dst);
dst++;
H_SET_LINENO_SIZE (h, *file_cursor - start);
}
-
/* Now we run through the list of frag chains in a segment and
make all the subsegment frags appear at the end of the
list, as if the seg 0 was extra long */
unsigned int addr;
abfd = bfd_openw (out_file_name, TARGET_FORMAT);
-
if (abfd == 0)
{
as_perror (_("FATAL: Can't create %s"), out_file_name);
md_do_align (SUB_SEGMENT_ALIGN (now_seg), (char *) NULL, 0, 0,
alignment_done);
#endif
- frag_align (SUB_SEGMENT_ALIGN (now_seg),
- subseg_text_p (now_seg) ? NOP_OPCODE : 0,
- 0);
+ if (subseg_text_p (now_seg))
+ frag_align_code (SUB_SEGMENT_ALIGN (now_seg), 0);
+ else
+ frag_align (SUB_SEGMENT_ALIGN (now_seg), 0, 0);
+
#ifdef md_do_align
alignment_done:
#endif
+
frag_wane (frag_now);
frag_now->fr_fix = 0;
know (frag_now->fr_next == NULL);
}
-
remove_subsegs ();
-
for (i = SEG_E0; i < SEG_UNKNOWN; i++)
{
relax_segment (segment_info[i].frchainP->frch_root, i);
}
/* Look for ".stab" segments and fill in their initial symbols
- correctly. */
+ correctly. */
for (i = SEG_E0; i < SEG_UNKNOWN; i++)
{
name = segment_info[i].name;
coff_header_append (abfd, &headers);
#if 0
/* Recent changes to write need this, but where it should
- go is up to Ken.. */
+ go is up to Ken.. */
if (bfd_close_all_done (abfd) == false)
as_fatal (_("Can't close %s: %s"), out_file_name,
bfd_errmsg (bfd_get_error ()));
demand_empty_rest_of_line ();
}
-
static void
obj_coff_text (ignore)
int ignore ATTRIBUTE_UNUSED;
subseg_new (".text", get_absolute_expression ());
}
-
static void
obj_coff_data (ignore)
int ignore ATTRIBUTE_UNUSED;
(unsigned int) (S_GET_NUMBER_AUXILIARY (debug) * AUXESZ));
} /* Move all the auxiliary information */
- /* Move the debug flags. */
+ /* Move the debug flags. */
SF_SET_DEBUG_FIELD (normal, SF_GET_DEBUG_FIELD (debug));
} /* c_symbol_merge() */
new_line->frag = (char *) frag;
new_line->next = (struct lineno_list *) NULL;
-
if (s->lineno_list_head == (struct lineno_list *) NULL)
{
s->lineno_list_head = new_line;
SA_SET_FILE_FNAME_ZEROS (symbolP, 0);
SA_SET_FILE_FNAME_OFFSET (symbolP, 1);
- if (filename_list_tail)
+ if (filename_list_tail)
filename_list_tail->next = f;
else
filename_list_head = f;
- filename_list_tail = f;
+ filename_list_tail = f;
}
- else
+ else
{
SA_SET_FILE_FNAME (symbolP, filename);
}
for (symbolP = symbol_rootP; symbolP; symbolP = symbol_next (symbolP))
{
/* Used to save the offset of the name. It is used to point
- to the string in memory but must be a file offset. */
+ to the string in memory but must be a file offset. */
register char *temp;
/* We can't fix the lnnoptr field in yank_symbols with the other
}
*p = 0;
- symbolP = symbol_find_or_make(name);
+ symbolP = symbol_find_or_make (name);
- if (S_GET_SEGMENT(symbolP) == SEG_UNKNOWN &&
- S_GET_VALUE(symbolP) == 0)
+ if (S_GET_SEGMENT (symbolP) == SEG_UNKNOWN &&
+ S_GET_VALUE (symbolP) == 0)
{
if (! need_pass_2)
{
(offsetT) temp, (char *) 0);
*p = 0;
subseg_set (current_seg, current_subseg); /* restore current seg */
- S_SET_SEGMENT(symbolP, SEG_E2);
- S_SET_STORAGE_CLASS(symbolP, C_STAT);
+ S_SET_SEGMENT (symbolP, SEG_E2);
+ S_SET_STORAGE_CLASS (symbolP, C_STAT);
}
}
else
- as_bad(_("Symbol %s already defined"), name);
+ as_bad (_("Symbol %s already defined"), name);
- demand_empty_rest_of_line();
+ demand_empty_rest_of_line ();
#endif
}
{
case rs_align:
case rs_align_code:
+ case rs_align_test:
case rs_org:
#ifdef HANDLE_ALIGN
HANDLE_ALIGN (frags);
if (fixP->fx_tcbit && SF_GET_CALLNAME (add_symbolP))
{
/* Relocation should be done via the associated 'bal' entry
- point symbol. */
+ point symbol. */
if (!SF_GET_BALNAME (tc_get_bal_of_call (add_symbolP)))
{
{
/* Difference of 2 symbols from same segment. Can't
make difference of 2 undefineds: 'value' means
- something different for N_UNDF. */
+ something different for N_UNDF. */
#ifdef TC_I960
/* Makes no sense to use the difference of 2 arbitrary symbols
as the target of a call instruction. */
}
else
{
- /* Different segments in subtraction. */
+ /* Different segments in subtraction. */
know (!(S_IS_EXTERNAL (sub_symbolP) && (S_GET_SEGMENT (sub_symbolP) == absolute_section)));
if ((S_GET_SEGMENT (sub_symbolP) == absolute_section))
}
#ifdef DIFF_EXPR_OK
else if (S_GET_SEGMENT (sub_symbolP) == this_segment_type
-#if 0 /* Okay for 68k, at least... */
+#if 0 /* Okay for 68k, at least... */
&& !pcrel
#endif
)
the i386 are relaxed, this could only arise with a
call instruction. */
- pcrel = 0; /* Lie. Don't want further pcrel processing. */
+ pcrel = 0; /* Lie. Don't want further pcrel processing. */
if (!TC_FORCE_RELOCATION (fixP))
{
fixP->fx_addsy = NULL;
break;
default:
-
#if defined(TC_A29K) || (defined(TE_PE) && defined(TC_I386)) || defined(TC_M88K)
/* This really should be handled in the linker, but
backward compatibility forbids. */
/* This is also true for 68k COFF on sysv machines
(Checked on Motorola sysv68 R3V6 and R3V7.1, and also on
UNIX System V/M68000, Release 1.0 from ATT/Bell Labs)
- Philippe De Muyter <phdm@info.ucl.ac.be>. */
+ Philippe De Muyter <phdm@info.ucl.ac.be>. */
if (S_IS_COMMON (add_symbolP))
add_number += S_GET_VALUE (add_symbolP);
#endif
break;
-
} /* switch on symbol seg */
} /* if not in local seg */
} /* if there was a + symbol */
(unsigned long) (fragP->fr_address + where));
#endif
} /* not a bit fix */
- } /* For each fixS in this segment. */
+ } /* For each fixS in this segment. */
} /* fixup_segment() */
#endif
char *stabstr_name;
unsigned int stroff;
- /* Make space for this first symbol. */
+ /* Make space for this first symbol. */
p = frag_more (12);
- /* Zero it out. */
+ /* Zero it out. */
memset (p, 0, 12);
as_where (&file, (unsigned int *) NULL);
stabstr_name = (char *) alloca (strlen (segment_info[seg].name) + 4);
int i, strsz = 0, nsyms;
fragS *frag = segment_info[seg].frchainP->frch_root;
- /* Look for the associated string table section. */
+ /* Look for the associated string table section. */
secname = segment_info[seg].name;
name = (char *) alloca (strlen (secname) + 4);
}
}
- /* If we found the section, get its size. */
+ /* If we found the section, get its size. */
if (stabstrseg != SEG_UNKNOWN)
strsz = size_section (abfd, stabstrseg);
nsyms = size_section (abfd, seg) / 12 - 1;
/* Look for the first frag of sufficient size for the initial stab
- symbol, and collect a pointer to it. */
+ symbol, and collect a pointer to it. */
while (frag && frag->fr_fix < 12)
frag = frag->fr_next;
assert (frag != 0);
assert (p != 0);
/* Write in the number of stab symbols and the size of the string
- table. */
+ table. */
bfd_h_put_16 (abfd, (bfd_vma) nsyms, (bfd_byte *) p + 6);
bfd_h_put_32 (abfd, (bfd_vma) strsz, (bfd_byte *) p + 8);
}
c_dot_file_symbol,
coff_frob_symbol,
0, /* frob_file */
+ 0, /* frob_file_before_adjust */
coff_frob_file_after_relocs,
0, /* s_get_size */
0, /* s_set_size */