to _bfd_is_local_label_name.
(bfd_target): Likewise.
* syms.c (bfd_is_local_label): Define as function, not macro.
(bfd_is_local_name): Define.
* libbfd.c (bfd_generic_is_local_label_name): Rename from
bfd_generic_is_local_label, and take a string rather than a
symbol.
* libbfd-in.h (_bfd_nosymbols_bfd_is_local_label): Don't define.
(_bfd_nosymbols_bfd_is_local_label_name): Define.
(bfd_generic_is_local_label): Don't declare.
(bfd_generic_is_local_label_name): Declare.
* bfd-in2.h, libbfd.h: Rebuild.
* All backends: Change local_label to local_label_name.
Thu Feb 27 18:36:23 1997 Ian Lance Taylor <ian@cygnus.com>
+ * targets.c (BFD_JUMP_TABLE_SYMBOLS): Change _bfd_is_local_label
+ to _bfd_is_local_label_name.
+ (bfd_target): Likewise.
+ * syms.c (bfd_is_local_label): Define as function, not macro.
+ (bfd_is_local_name): Define.
+ * libbfd.c (bfd_generic_is_local_label_name): Rename from
+ bfd_generic_is_local_label, and take a string rather than a
+ symbol.
+ * libbfd-in.h (_bfd_nosymbols_bfd_is_local_label): Don't define.
+ (_bfd_nosymbols_bfd_is_local_label_name): Define.
+ (bfd_generic_is_local_label): Don't declare.
+ (bfd_generic_is_local_label_name): Declare.
+ * bfd-in2.h, libbfd.h: Rebuild.
+ * All backends: Change local_label to local_label_name.
+
* elf32-mips.c (struct mips_got_info): Add assigned_gotno field.
(mips_elf_relocate_got_local): Change return type to boolean.
Don't assume that the first zero entry is unassigned; instead, use
struct symbol_cache_entry;
struct bfd_link_info;
struct bfd_link_hash_entry;
+struct bfd_elf_version_tree;
#endif
extern bfd_vma bfd_ecoff_get_gp_value PARAMS ((bfd * abfd));
extern boolean bfd_ecoff_set_gp_value PARAMS ((bfd *abfd, bfd_vma gp_value));
PARAMS ((bfd *, struct bfd_link_info *));
extern boolean bfd_elf32_size_dynamic_sections
PARAMS ((bfd *, const char *, const char *, boolean, const char *,
- const char * const *, struct bfd_link_info *, struct sec **));
+ const char * const *, struct bfd_link_info *, struct sec **,
+ struct bfd_elf_version_tree *));
extern boolean bfd_elf64_size_dynamic_sections
PARAMS ((bfd *, const char *, const char *, boolean, const char *,
- const char * const *, struct bfd_link_info *, struct sec **));
+ const char * const *, struct bfd_link_info *, struct sec **,
+ struct bfd_elf_version_tree *));
extern void bfd_elf_set_dt_needed_name PARAMS ((bfd *, const char *));
extern const char *bfd_elf_get_dt_soname PARAMS ((bfd *));
boolean
bfd_is_local_label PARAMS ((bfd *abfd, asymbol *sym));
-#define bfd_is_local_label(abfd, sym) \
- BFD_SEND (abfd, _bfd_is_local_label,(abfd, sym))
+boolean
+bfd_is_local_label_name PARAMS ((bfd *abfd, const char *name));
+
+#define bfd_is_local_label_name(abfd, name) \
+ BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
#define bfd_canonicalize_symtab(abfd, location) \
BFD_SEND (abfd, _bfd_canonicalize_symtab,\
(abfd, location))
CAT(NAME,_make_empty_symbol),\
CAT(NAME,_print_symbol),\
CAT(NAME,_get_symbol_info),\
-CAT(NAME,_bfd_is_local_label),\
+CAT(NAME,_bfd_is_local_label_name),\
CAT(NAME,_get_lineno),\
CAT(NAME,_find_nearest_line),\
CAT(NAME,_bfd_make_debug_symbol),\
struct symbol_cache_entry *,
symbol_info *));
#define bfd_get_symbol_info(b,p,e) BFD_SEND(b, _bfd_get_symbol_info, (b,p,e))
- boolean (*_bfd_is_local_label) PARAMS ((bfd *, asymbol *));
+ boolean (*_bfd_is_local_label_name) PARAMS ((bfd *, const char *));
alent * (*_get_lineno) PARAMS ((bfd *, struct symbol_cache_entry *));
boolean (*_bfd_find_nearest_line) PARAMS ((bfd *abfd,
/* Support for the generic parts of most COFF variants, for BFD.
- Copyright 1990, 91, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
+ Copyright 1990, 91, 92, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
previous = current;
}
+ /* Make sure the relocations are aligned. */
+ sofar = BFD_ALIGN (sofar, 1 << COFF_DEFAULT_SECTION_ALIGNMENT_POWER);
+
obj_relocbase (abfd) = sofar;
abfd->output_has_begun = true;
#define __A_MAGIC_SET__
#endif /* A29K */
#ifdef TIC80
- internal_a.magic = TIC80MAGIC;
+ internal_a.magic = TIC80_ARCH_MAGIC;
#define __A_MAGIC_SET__
#endif /* TIC80 */
#ifdef I860
#define coff_bfd_print_private_bfd_data _bfd_generic_bfd_print_private_bfd_data
#endif
-#ifndef coff_bfd_is_local_label
-#define coff_bfd_is_local_label bfd_generic_is_local_label
+#ifndef coff_bfd_is_local_label_name
+#define coff_bfd_is_local_label_name bfd_generic_is_local_label_name
#endif
#ifndef coff_read_minisymbols
#define coff_read_minisymbols _bfd_generic_read_minisymbols
/* Target definitions for NN-bit ELF
- Copyright 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
#define bfd_elfNN_bfd_set_private_flags \
((boolean (*) PARAMS ((bfd *, flagword))) bfd_true)
#endif
-#ifndef bfd_elfNN_bfd_is_local_label
-#define bfd_elfNN_bfd_is_local_label bfd_generic_is_local_label
+#ifndef bfd_elfNN_bfd_is_local_label_name
+#define bfd_elfNN_bfd_is_local_label_name bfd_generic_is_local_label_name
#endif
#ifndef bfd_elfNN_get_dynamic_reloc_upper_bound
PARAMS ((bfd *abfd, PTR file, asymbol *symbol, bfd_print_symbol_type how));
static void evax_get_symbol_info
PARAMS ((bfd *abfd, asymbol *symbol, symbol_info *ret));
-static boolean evax_bfd_is_local_label PARAMS ((bfd *abfd, asymbol *symbol));
+static boolean evax_bfd_is_local_label_name PARAMS ((bfd *abfd, const char *));
static alent *evax_get_lineno PARAMS ((bfd *abfd, asymbol *symbol));
static boolean evax_find_nearest_line
PARAMS ((bfd *abfd, asection *section, asymbol **symbols, bfd_vma offset,
a compiler generated local label, else return false. */
static boolean
-evax_bfd_is_local_label (abfd, symbol)
+evax_bfd_is_local_label_name (abfd, name)
bfd *abfd;
- asymbol *symbol;
+ const char *name;
{
#if EVAX_DEBUG
- evax_debug (1, "evax_bfd_is_local_label(%p, %p)\n", abfd, symbol);
+ evax_debug (1, "evax_bfd_is_local_label_name(%p, %s)\n", abfd, name);
#endif
return false;
}
/* libbfd.h -- Declarations used by bfd library *implementation*.
(This include file is not for users of the library.)
- Copyright 1990, 91, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
+ Copyright 1990, 91, 92, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
Written by Cygnus Support.
** NOTE: libbfd.h is a GENERATED file. Don't change it; instead,
((void (*) PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type))) bfd_void)
#define _bfd_nosymbols_get_symbol_info \
((void (*) PARAMS ((bfd *, asymbol *, symbol_info *))) bfd_void)
-#define _bfd_nosymbols_bfd_is_local_label \
- ((boolean (*) PARAMS ((bfd *, asymbol *))) bfd_false)
+#define _bfd_nosymbols_bfd_is_local_label_name \
+ ((boolean (*) PARAMS ((bfd *, const char *))) bfd_false)
#define _bfd_nosymbols_get_lineno \
((alent *(*) PARAMS ((bfd *, asymbol *))) bfd_nullvoidptr)
#define _bfd_nosymbols_find_nearest_line \
\f
/* Generic routine to determine of the given symbol is a local
label. */
-extern boolean bfd_generic_is_local_label PARAMS ((bfd *, asymbol *));
+extern boolean bfd_generic_is_local_label_name PARAMS ((bfd *, const char *));
/* Generic minisymbol routines. */
extern long _bfd_generic_read_minisymbols
extern bfd_reloc_status_type _bfd_relocate_contents
PARAMS ((reloc_howto_type *, bfd *, bfd_vma, bfd_byte *));
+/* Link stabs in sections in the first pass. */
+
+extern boolean _bfd_link_section_stabs
+ PARAMS ((bfd *, PTR *, asection *, asection *, PTR *));
+
+/* Write out the .stab section when linking stabs in sections. */
+
+extern boolean _bfd_write_section_stabs
+ PARAMS ((bfd *, asection *, PTR *, bfd_byte *));
+
+/* Write out the .stabstr string table when linking stabs in sections. */
+
+extern boolean _bfd_write_stab_strings PARAMS ((bfd *, PTR *));
+
/* Create a string table. */
extern struct bfd_strtab_hash *_bfd_stringtab_init PARAMS ((void));
FILE * bfd_cache_lookup_worker PARAMS ((bfd *));
extern bfd *bfd_last_cache;
-
-/* Now Steve, what's the story here? */
-#ifdef lint
-#define itos(x) "l"
-#define stoi(x) 1
-#else
-#define itos(x) ((char*)(x))
-#define stoi(x) ((int)(x))
-#endif
/* List of supported target vectors, and the default vector (if
bfd_default_vector[0] is NULL, there is no default). */
extern bfd_vma _bfd_get_gp_value PARAMS ((bfd *));
extern void _bfd_set_gp_value PARAMS ((bfd *, bfd_vma));
+/* Function shared by the COFF and ELF SH backends, which have no
+ other common header files. */
+
+extern boolean _bfd_sh_align_load_span
+ PARAMS ((bfd *, asection *, bfd_byte *,
+ boolean (*) (bfd *, asection *, PTR, bfd_byte *, bfd_vma),
+ PTR, bfd_vma **, bfd_vma *, bfd_vma, bfd_vma, boolean *));
+
/* And more follows */
((void (*) PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type))) bfd_void)
#define _bfd_nosymbols_get_symbol_info \
((void (*) PARAMS ((bfd *, asymbol *, symbol_info *))) bfd_void)
-#define _bfd_nosymbols_bfd_is_local_label \
- ((boolean (*) PARAMS ((bfd *, asymbol *))) bfd_false)
+#define _bfd_nosymbols_bfd_is_local_label_name \
+ ((boolean (*) PARAMS ((bfd *, const char *))) bfd_false)
#define _bfd_nosymbols_get_lineno \
((alent *(*) PARAMS ((bfd *, asymbol *))) bfd_nullvoidptr)
#define _bfd_nosymbols_find_nearest_line \
\f
/* Generic routine to determine of the given symbol is a local
label. */
-extern boolean bfd_generic_is_local_label PARAMS ((bfd *, asymbol *));
+extern boolean bfd_generic_is_local_label_name PARAMS ((bfd *, const char *));
/* Generic minisymbol routines. */
extern long _bfd_generic_read_minisymbols
"BFD_RELOC_M32R_HI16_ULO",
"BFD_RELOC_M32R_HI16_SLO",
"BFD_RELOC_M32R_LO16",
+ "BFD_RELOC_M32R_SDA16",
/* end-sanitize-m32r */
/* start-sanitize-v850 */
/* Generic symbol-table support for the BFD library.
- Copyright (C) 1990, 91, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
+ Copyright (C) 1990, 91, 92, 93, 94, 95, 96, 1997
+ Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
DESCRIPTION
Return true if the given symbol @var{sym} in the BFD @var{abfd} is
a compiler generated local label, else return false.
-.#define bfd_is_local_label(abfd, sym) \
-. BFD_SEND (abfd, _bfd_is_local_label,(abfd, sym))
+*/
+
+boolean
+bfd_is_local_label (abfd, sym)
+ bfd *abfd;
+ asymbol *sym;
+{
+ if ((sym->flags & (BSF_GLOBAL | BSF_WEAK)) != 0)
+ return false;
+ return bfd_is_local_label_name (abfd, sym->name);
+}
+
+/*
+FUNCTION
+ bfd_is_local_label_name
+
+SYNOPSIS
+ boolean bfd_is_local_label_name(bfd *abfd, const char *name);
+
+DESCRIPTION
+ Return true if a symbol with the name @var{name} in the BFD
+ @var{abfd} is a compiler generated local label, else return
+ false. This just checks whether the name has the form of a
+ local label.
+
+.#define bfd_is_local_label_name(abfd, name) \
+. BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
*/
/*
Not enough memory exists to create private data for @var{osec}.
.#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
-. BFD_SEND (ibfd, _bfd_copy_private_symbol_data, \
+. BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
. (ibfd, isymbol, obfd, osymbol))
*/
/* Generic target-file-type support for the BFD library.
- Copyright 1990, 91, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
+ Copyright 1990, 91, 92, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
.CAT(NAME,_make_empty_symbol),\
.CAT(NAME,_print_symbol),\
.CAT(NAME,_get_symbol_info),\
-.CAT(NAME,_bfd_is_local_label),\
+.CAT(NAME,_bfd_is_local_label_name),\
.CAT(NAME,_get_lineno),\
.CAT(NAME,_find_nearest_line),\
.CAT(NAME,_bfd_make_debug_symbol),\
. struct symbol_cache_entry *,
. symbol_info *));
.#define bfd_get_symbol_info(b,p,e) BFD_SEND(b, _bfd_get_symbol_info, (b,p,e))
-. boolean (*_bfd_is_local_label) PARAMS ((bfd *, asymbol *));
+. boolean (*_bfd_is_local_label_name) PARAMS ((bfd *, const char *));
.
. alent * (*_get_lineno) PARAMS ((bfd *, struct symbol_cache_entry *));
. boolean (*_bfd_find_nearest_line) PARAMS ((bfd *abfd,