* read.c (s_lcomm_internal): Make global.

* read.h (s_lcomm_internal): Declare.
	* config/obj-elf.c (elf_pseudo_table): Handle lcomm.
	(obj_elf_lcomm): New function.
This commit is contained in:
Alan Modra 2003-12-13 08:59:24 +00:00
parent e13bab5a71
commit 13c5698440
4 changed files with 31 additions and 12 deletions

View file

@ -1,3 +1,10 @@
2003-12-13 Alan Modra <amodra@bigpond.net.au>
* read.c (s_lcomm_internal): Make global.
* read.h (s_lcomm_internal): Declare.
* config/obj-elf.c (elf_pseudo_table): Handle lcomm.
(obj_elf_lcomm): New function.
2003-12-13 Alan Modra <amodra@bigpond.net.au>
* read.c: Remove unneeded prototypes.

View file

@ -85,12 +85,14 @@ static void obj_elf_symver PARAMS ((int));
static void obj_elf_subsection PARAMS ((int));
static void obj_elf_popsection PARAMS ((int));
static void obj_elf_tls_common PARAMS ((int));
static void obj_elf_lcomm (int);
static const pseudo_typeS elf_pseudo_table[] =
{
{"comm", obj_elf_common, 0},
{"common", obj_elf_common, 1},
{"ident", obj_elf_ident, 0},
{"lcomm", obj_elf_lcomm, 0},
{"local", obj_elf_local, 0},
{"previous", obj_elf_previous, 0},
{"section", obj_elf_section, 0},
@ -381,6 +383,15 @@ obj_elf_tls_common (ignore)
symbol_get_bfdsym (symbolP)->flags |= BSF_THREAD_LOCAL;
}
static void
obj_elf_lcomm (int ignore ATTRIBUTE_UNUSED)
{
symbolS *symbolP = s_comm_internal (0, s_lcomm_internal);
if (symbolP)
symbol_get_bfdsym (symbolP)->flags |= BSF_OBJECT;
}
static void
obj_elf_local (ignore)
int ignore ATTRIBUTE_UNUSED;

View file

@ -2022,7 +2022,7 @@ parse_align (int align_bytes)
(alignment as a power of 2), or 2 if this was a ".bss" directive
with alignment in bytes. */
static symbolS *
symbolS *
s_lcomm_internal (int needs_align, symbolS *symbolP, addressT size)
{
addressT align = 0;

View file

@ -142,6 +142,7 @@ extern void s_align_ptwo (int);
extern void bss_alloc (symbolS *, addressT, int);
extern offsetT parse_align (int);
extern symbolS *s_comm_internal (int, symbolS *(*) (int, symbolS *, addressT));
extern symbolS *s_lcomm_internal (int, symbolS *, addressT);
extern void s_app_file_string (char *);
extern void s_app_file (int);
extern void s_app_line (int);