- Rebase on 2.20.51.0.7 tarball.
- Delete redundant patches: binutils-2.20.51.0.2-add-needed.patch, binutils-2.20.51.0.2-do-not-set-ifunc.patch, binutils-2.20.51.0.2-enable-gold.patch, binutils-2.20.51.0.2-gas-expr.patch, binutils-2.20.51.0.2-ifunc-ld-s.patch, binutils-2.20.51.0.2-lwp.patch, binutils-2.20.51.0.2-ppc-hidden-plt-relocs.patch, binutils-2.20.51.0.2-x86-hash-table.patch, - Do not allow unique symbols to be bound locally. (PR ld/11434) - Add support for DWARF4 debug information.
This commit is contained in:
parent
7272e92f0a
commit
711d8b61df
@ -1,4 +1 @@
|
||||
binutils-2.20.51.0.2.tar.bz2
|
||||
binutils-2.20.51.0.2
|
||||
current-gcc
|
||||
i386
|
||||
binutils-2.20.51.0.7.tar.bz2
|
||||
|
@ -1,430 +0,0 @@
|
||||
diff -rup ../binutils-2.20.51.0.2/bfd/elflink.c ./bfd/elflink.c
|
||||
--- ../binutils-2.20.51.0.2/bfd/elflink.c 2010-01-20 08:27:19.000000000 +0000
|
||||
+++ ./bfd/elflink.c 2010-01-20 08:35:12.000000000 +0000
|
||||
@@ -3918,6 +3918,7 @@ error_free_dyn:
|
||||
bfd_boolean common;
|
||||
unsigned int old_alignment;
|
||||
bfd *old_bfd;
|
||||
+ bfd * undef_bfd = NULL;
|
||||
|
||||
override = FALSE;
|
||||
|
||||
@@ -4042,6 +4043,20 @@ error_free_dyn:
|
||||
unsigned int vernum = 0;
|
||||
bfd_boolean skip;
|
||||
|
||||
+ /* If this is a definition of a symbol which was previously
|
||||
+ referenced in a non-weak manner then make a note of the bfd
|
||||
+ that contained the reference. This is used if we need to
|
||||
+ refer to the source of the reference later on. */
|
||||
+ if (! bfd_is_und_section (sec))
|
||||
+ {
|
||||
+ h = elf_link_hash_lookup (elf_hash_table (info), name, FALSE, FALSE, FALSE);
|
||||
+
|
||||
+ if (h != NULL
|
||||
+ && h->root.type == bfd_link_hash_undefined
|
||||
+ && h->root.u.undef.abfd)
|
||||
+ undef_bfd = h->root.u.undef.abfd;
|
||||
+ }
|
||||
+
|
||||
if (ever == NULL)
|
||||
{
|
||||
if (info->default_imported_symver)
|
||||
@@ -4149,6 +4164,19 @@ error_free_dyn:
|
||||
name = newname;
|
||||
}
|
||||
|
||||
+ /* If necessary, make a second attempt to locate the bfd
|
||||
+ containing an unresolved, non-weak reference to the
|
||||
+ current symbol. */
|
||||
+ if (! bfd_is_und_section (sec) && undef_bfd == NULL)
|
||||
+ {
|
||||
+ h = elf_link_hash_lookup (elf_hash_table (info), name, FALSE, FALSE, FALSE);
|
||||
+
|
||||
+ if (h != NULL
|
||||
+ && h->root.type == bfd_link_hash_undefined
|
||||
+ && h->root.u.undef.abfd)
|
||||
+ undef_bfd = h->root.u.undef.abfd;
|
||||
+ }
|
||||
+
|
||||
if (!_bfd_elf_merge_symbol (abfd, info, name, isym, &sec,
|
||||
&value, &old_alignment,
|
||||
sym_hash, &skip, &override,
|
||||
@@ -4502,13 +4530,18 @@ error_free_dyn:
|
||||
/* A symbol from a library loaded via DT_NEEDED of some
|
||||
other library is referenced by a regular object.
|
||||
Add a DT_NEEDED entry for it. Issue an error if
|
||||
- --no-add-needed is used. */
|
||||
- if ((elf_dyn_lib_class (abfd) & DYN_NO_NEEDED) != 0)
|
||||
+ --no-add-needed is used and the reference was not
|
||||
+ a weak one. */
|
||||
+ if (undef_bfd != NULL
|
||||
+ && (elf_dyn_lib_class (abfd) & DYN_NO_NEEDED) != 0)
|
||||
{
|
||||
(*_bfd_error_handler)
|
||||
- (_("%s: invalid DSO for symbol `%s' definition"),
|
||||
+ (_("%B: undefined reference to symbol '%s'"),
|
||||
+ undef_bfd, name);
|
||||
+ (*_bfd_error_handler)
|
||||
+ (_("note: '%s' is defined in DSO %B so try adding it to the linker command line"),
|
||||
abfd, name);
|
||||
- bfd_set_error (bfd_error_bad_value);
|
||||
+ bfd_set_error (bfd_error_invalid_operation);
|
||||
goto error_free_vers;
|
||||
}
|
||||
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/emultempl/elf32.em ./ld/emultempl/elf32.em
|
||||
--- ../binutils-2.20.51.0.2/ld/emultempl/elf32.em 2009-10-09 23:26:22.000000000 +0100
|
||||
+++ ./ld/emultempl/elf32.em 2010-01-13 16:01:13.000000000 +0000
|
||||
@@ -110,7 +110,7 @@ fi
|
||||
|
||||
if test x"$LDEMUL_RECOGNIZED_FILE" != xgld"${EMULATION_NAME}"_load_symbols; then
|
||||
fragment <<EOF
|
||||
-/* Handle as_needed DT_NEEDED. */
|
||||
+/* Handle the generation of DT_NEEDED tags. */
|
||||
|
||||
static bfd_boolean
|
||||
gld${EMULATION_NAME}_load_symbols (lang_input_statement_type *entry)
|
||||
@@ -120,13 +120,13 @@ gld${EMULATION_NAME}_load_symbols (lang_
|
||||
/* Tell the ELF linker that we don't want the output file to have a
|
||||
DT_NEEDED entry for this file, unless it is used to resolve
|
||||
references in a regular object. */
|
||||
- if (entry->as_needed)
|
||||
+ if (entry->add_DT_NEEDED_for_regular)
|
||||
link_class = DYN_AS_NEEDED;
|
||||
|
||||
/* Tell the ELF linker that we don't want the output file to have a
|
||||
DT_NEEDED entry for any dynamic library in DT_NEEDED tags from
|
||||
this file at all. */
|
||||
- if (!entry->add_needed)
|
||||
+ if (!entry->add_DT_NEEDED_for_dynamic)
|
||||
link_class |= DYN_NO_ADD_NEEDED;
|
||||
|
||||
if (entry->just_syms_flag
|
||||
@@ -134,7 +134,7 @@ gld${EMULATION_NAME}_load_symbols (lang_
|
||||
einfo (_("%P%F: --just-symbols may not be used on DSO: %B\n"),
|
||||
entry->the_bfd);
|
||||
|
||||
- if (!link_class
|
||||
+ if (link_class == 0
|
||||
|| (bfd_get_file_flags (entry->the_bfd) & DYNAMIC) == 0)
|
||||
return FALSE;
|
||||
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/ldgram.y ./ld/ldgram.y
|
||||
--- ../binutils-2.20.51.0.2/ld/ldgram.y 2009-09-08 18:11:39.000000000 +0100
|
||||
+++ ./ld/ldgram.y 2010-01-13 16:01:16.000000000 +0000
|
||||
@@ -378,17 +378,17 @@ input_list:
|
||||
{ lang_add_input_file($2,lang_input_file_is_l_enum,
|
||||
(char *)NULL); }
|
||||
| AS_NEEDED '('
|
||||
- { $<integer>$ = as_needed; as_needed = TRUE; }
|
||||
+ { $<integer>$ = add_DT_NEEDED_for_regular; add_DT_NEEDED_for_regular = TRUE; }
|
||||
input_list ')'
|
||||
- { as_needed = $<integer>3; }
|
||||
+ { add_DT_NEEDED_for_regular = $<integer>3; }
|
||||
| input_list ',' AS_NEEDED '('
|
||||
- { $<integer>$ = as_needed; as_needed = TRUE; }
|
||||
+ { $<integer>$ = add_DT_NEEDED_for_regular; add_DT_NEEDED_for_regular = TRUE; }
|
||||
input_list ')'
|
||||
- { as_needed = $<integer>5; }
|
||||
+ { add_DT_NEEDED_for_regular = $<integer>5; }
|
||||
| input_list AS_NEEDED '('
|
||||
- { $<integer>$ = as_needed; as_needed = TRUE; }
|
||||
+ { $<integer>$ = add_DT_NEEDED_for_regular; add_DT_NEEDED_for_regular = TRUE; }
|
||||
input_list ')'
|
||||
- { as_needed = $<integer>4; }
|
||||
+ { add_DT_NEEDED_for_regular = $<integer>4; }
|
||||
;
|
||||
|
||||
sections:
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/ldlang.c ./ld/ldlang.c
|
||||
--- ../binutils-2.20.51.0.2/ld/ldlang.c 2009-10-09 23:25:30.000000000 +0100
|
||||
+++ ./ld/ldlang.c 2010-01-13 16:01:16.000000000 +0000
|
||||
@@ -1056,8 +1056,8 @@ new_afile (const char *name,
|
||||
p->next_real_file = NULL;
|
||||
p->next = NULL;
|
||||
p->dynamic = config.dynamic_link;
|
||||
- p->add_needed = add_needed;
|
||||
- p->as_needed = as_needed;
|
||||
+ p->add_DT_NEEDED_for_dynamic = add_DT_NEEDED_for_dynamic;
|
||||
+ p->add_DT_NEEDED_for_regular = add_DT_NEEDED_for_regular;
|
||||
p->whole_archive = whole_archive;
|
||||
p->loaded = FALSE;
|
||||
lang_statement_append (&input_file_chain,
|
||||
@@ -2592,7 +2592,8 @@ load_symbols (lang_input_statement_type
|
||||
{
|
||||
bfd_error_type err;
|
||||
bfd_boolean save_ldlang_sysrooted_script;
|
||||
- bfd_boolean save_as_needed, save_add_needed;
|
||||
+ bfd_boolean save_add_DT_NEEDED_for_regular;
|
||||
+ bfd_boolean save_add_DT_NEEDED_for_dynamic;
|
||||
|
||||
err = bfd_get_error ();
|
||||
|
||||
@@ -2623,10 +2624,10 @@ load_symbols (lang_input_statement_type
|
||||
push_stat_ptr (place);
|
||||
save_ldlang_sysrooted_script = ldlang_sysrooted_script;
|
||||
ldlang_sysrooted_script = entry->sysrooted;
|
||||
- save_as_needed = as_needed;
|
||||
- as_needed = entry->as_needed;
|
||||
- save_add_needed = add_needed;
|
||||
- add_needed = entry->add_needed;
|
||||
+ save_add_DT_NEEDED_for_regular = add_DT_NEEDED_for_regular;
|
||||
+ add_DT_NEEDED_for_regular = entry->add_DT_NEEDED_for_regular;
|
||||
+ save_add_DT_NEEDED_for_dynamic = add_DT_NEEDED_for_dynamic;
|
||||
+ add_DT_NEEDED_for_dynamic = entry->add_DT_NEEDED_for_dynamic;
|
||||
|
||||
ldfile_assumed_script = TRUE;
|
||||
parser_input = input_script;
|
||||
@@ -2637,8 +2638,8 @@ load_symbols (lang_input_statement_type
|
||||
ldfile_assumed_script = FALSE;
|
||||
|
||||
ldlang_sysrooted_script = save_ldlang_sysrooted_script;
|
||||
- as_needed = save_as_needed;
|
||||
- add_needed = save_add_needed;
|
||||
+ add_DT_NEEDED_for_regular = save_add_DT_NEEDED_for_regular;
|
||||
+ add_DT_NEEDED_for_dynamic = save_add_DT_NEEDED_for_dynamic;
|
||||
pop_stat_ptr ();
|
||||
|
||||
return TRUE;
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/ldlang.h ./ld/ldlang.h
|
||||
--- ../binutils-2.20.51.0.2/ld/ldlang.h 2009-10-09 23:25:30.000000000 +0100
|
||||
+++ ./ld/ldlang.h 2010-01-13 16:01:13.000000000 +0000
|
||||
@@ -270,11 +270,11 @@ typedef struct lang_input_statement_stru
|
||||
|
||||
/* Whether DT_NEEDED tags should be added for dynamic libraries in
|
||||
DT_NEEDED tags from this entry. */
|
||||
- unsigned int add_needed : 1;
|
||||
+ unsigned int add_DT_NEEDED_for_dynamic : 1;
|
||||
|
||||
/* Whether this entry should cause a DT_NEEDED tag only when
|
||||
satisfying references from regular files, or always. */
|
||||
- unsigned int as_needed : 1;
|
||||
+ unsigned int add_DT_NEEDED_for_regular : 1;
|
||||
|
||||
/* Whether to include the entire contents of an archive. */
|
||||
unsigned int whole_archive : 1;
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/ldmain.c ./ld/ldmain.c
|
||||
--- ../binutils-2.20.51.0.2/ld/ldmain.c 2010-01-20 08:27:18.000000000 +0000
|
||||
+++ ./ld/ldmain.c 2010-01-13 16:01:16.000000000 +0000
|
||||
@@ -93,13 +93,14 @@ bfd_boolean version_printed;
|
||||
/* Nonzero means link in every member of an archive. */
|
||||
bfd_boolean whole_archive;
|
||||
|
||||
-/* Nonzero means create DT_NEEDED entries only if a dynamic library
|
||||
- actually satisfies some reference in a regular object. */
|
||||
-bfd_boolean as_needed;
|
||||
-
|
||||
-/* Nonzero means never create DT_NEEDED entries for dynamic libraries
|
||||
- in DT_NEEDED tags. */
|
||||
-bfd_boolean add_needed = TRUE;
|
||||
+/* True means only create DT_NEEDED entries for dynamic libraries
|
||||
+ if they actually satisfy some reference in a regular object. */
|
||||
+bfd_boolean add_DT_NEEDED_for_regular;
|
||||
+
|
||||
+/* True means create DT_NEEDED entries for dynamic libraries that
|
||||
+ are DT_NEEDED by dynamic libraries specifically mentioned on
|
||||
+ the command line. */
|
||||
+bfd_boolean add_DT_NEEDED_for_dynamic = TRUE;
|
||||
|
||||
/* TRUE if we should demangle symbol names. */
|
||||
bfd_boolean demangling;
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/ldmain.h ./ld/ldmain.h
|
||||
--- ../binutils-2.20.51.0.2/ld/ldmain.h 2009-10-09 23:26:22.000000000 +0100
|
||||
+++ ./ld/ldmain.h 2010-01-13 16:01:12.000000000 +0000
|
||||
@@ -1,6 +1,6 @@
|
||||
/* ldmain.h -
|
||||
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2002, 2003, 2004,
|
||||
- 2005, 2007, 2008 Free Software Foundation, Inc.
|
||||
+ 2005, 2007, 2008, 2009 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of the GNU Binutils.
|
||||
|
||||
@@ -34,8 +34,8 @@ extern bfd_boolean trace_files;
|
||||
extern bfd_boolean trace_file_tries;
|
||||
extern bfd_boolean version_printed;
|
||||
extern bfd_boolean whole_archive;
|
||||
-extern bfd_boolean as_needed;
|
||||
-extern bfd_boolean add_needed;
|
||||
+extern bfd_boolean add_DT_NEEDED_for_regular;
|
||||
+extern bfd_boolean add_DT_NEEDED_for_dynamic;
|
||||
extern bfd_boolean demangling;
|
||||
extern enum report_method how_to_report_unresolved_symbols;
|
||||
extern int g_switch_value;
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/ld.texinfo ./ld/ld.texinfo
|
||||
--- ../binutils-2.20.51.0.2/ld/ld.texinfo 2010-01-20 08:27:18.000000000 +0000
|
||||
+++ ./ld/ld.texinfo 2010-01-13 16:01:12.000000000 +0000
|
||||
@@ -1132,27 +1132,24 @@ restore the old behaviour.
|
||||
@item --as-needed
|
||||
@itemx --no-as-needed
|
||||
This option affects ELF DT_NEEDED tags for dynamic libraries mentioned
|
||||
-on the command line after the @option{--as-needed} option. Normally,
|
||||
+on the command line after the @option{--as-needed} option. Normally
|
||||
the linker will add a DT_NEEDED tag for each dynamic library mentioned
|
||||
on the command line, regardless of whether the library is actually
|
||||
-needed. @option{--as-needed} causes a DT_NEEDED tag to only be emitted
|
||||
-for a library that satisfies a symbol reference from regular objects
|
||||
-which is undefined at the point that the library was linked, or, if
|
||||
-the library is not found in the DT_NEEDED lists of other libraries
|
||||
-linked up to that point, a reference from another dynamic library.
|
||||
+needed or not. @option{--as-needed} causes a DT_NEEDED tag to only be
|
||||
+emitted for a library that satisfies an undefined symbol reference
|
||||
+from a regular object file or, if the library is not found in the
|
||||
+DT_NEEDED lists of other libraries linked up to that point, an
|
||||
+undefined symbol reference from another dynamic library.
|
||||
@option{--no-as-needed} restores the default behaviour.
|
||||
|
||||
@kindex --add-needed
|
||||
@kindex --no-add-needed
|
||||
@item --add-needed
|
||||
@itemx --no-add-needed
|
||||
-This option affects the treatment of dynamic libraries from ELF
|
||||
-DT_NEEDED tags in dynamic libraries mentioned on the command line after
|
||||
-the @option{--no-add-needed} option. Normally, the linker will add
|
||||
-a DT_NEEDED tag for each dynamic library from DT_NEEDED tags.
|
||||
-@option{--no-add-needed} causes DT_NEEDED tags will never be emitted
|
||||
-for those libraries from DT_NEEDED tags. @option{--add-needed} restores
|
||||
-the default behaviour.
|
||||
+These two options have been deprecated because of the similarity of
|
||||
+their names to the @option{--as-needed} and @option{--no-as-needed}
|
||||
+options. They have been replaced by @option{--copy-dt-needed-entries}
|
||||
+and @option{--no-copy-dt-needed-entries}.
|
||||
|
||||
@kindex -assert @var{keyword}
|
||||
@item -assert @var{keyword}
|
||||
@@ -1253,6 +1250,29 @@ Section overlap is not usually checked f
|
||||
force checking in that case by using the @option{--check-sections}
|
||||
option.
|
||||
|
||||
+@kindex --copy-dt-needed-entries
|
||||
+@kindex --no-copy-dt-needed-entries
|
||||
+@item --copy-dt-needed-entries
|
||||
+@itemx --no-copy-dt-needed-entries
|
||||
+This option affects the treatment of dynamic libraries referred to
|
||||
+by DT_NEEDED tags @emph{inside} ELF dynamic libraries mentioned on the
|
||||
+command line. Normally the linker will add a DT_NEEDED tag to the
|
||||
+output binary for each library mentioned in a DT_NEEDED tag in an
|
||||
+input dynamic library. With @option{--no-copy-dt-needed-entries}
|
||||
+specified on the command line however any dynamic libraries that
|
||||
+follow it will have their DT_NEEDED entries ignored. The default
|
||||
+behaviour can be restored with @option{--copy-dt-needed-entries}.
|
||||
+
|
||||
+This option also has an effect on the resolution of symbols in dynamic
|
||||
+libraries. With the default setting dynamic libraries mentioned on
|
||||
+the command line will be recursively searched, following their
|
||||
+DT_NEEDED tags to other libraries, in order to resolve symbols
|
||||
+required by the output binary. With
|
||||
+@option{--no-copy-dt-needed-entries} specified however the searching
|
||||
+of dynamic libraries that follow it will stop with the dynamic
|
||||
+library itself. No DT_NEEDED links will be traversed to resolve
|
||||
+symbols.
|
||||
+
|
||||
@cindex cross reference table
|
||||
@kindex --cref
|
||||
@item --cref
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/lexsup.c ./ld/lexsup.c
|
||||
--- ../binutils-2.20.51.0.2/ld/lexsup.c 2009-10-09 23:26:22.000000000 +0100
|
||||
+++ ./ld/lexsup.c 2010-01-13 16:01:15.000000000 +0000
|
||||
@@ -125,10 +125,10 @@ enum option_values
|
||||
OPTION_SPLIT_BY_RELOC,
|
||||
OPTION_SPLIT_BY_FILE ,
|
||||
OPTION_WHOLE_ARCHIVE,
|
||||
- OPTION_ADD_NEEDED,
|
||||
- OPTION_NO_ADD_NEEDED,
|
||||
- OPTION_AS_NEEDED,
|
||||
- OPTION_NO_AS_NEEDED,
|
||||
+ OPTION_ADD_DT_NEEDED_FOR_DYNAMIC,
|
||||
+ OPTION_NO_ADD_DT_NEEDED_FOR_DYNAMIC,
|
||||
+ OPTION_ADD_DT_NEEDED_FOR_REGULAR,
|
||||
+ OPTION_NO_ADD_DT_NEEDED_FOR_REGULAR,
|
||||
OPTION_WRAP,
|
||||
OPTION_FORCE_EXE_SUFFIX,
|
||||
OPTION_GC_SECTIONS,
|
||||
@@ -333,19 +333,22 @@ static const struct ld_option ld_options
|
||||
OPTION_NO_ACCEPT_UNKNOWN_INPUT_ARCH},
|
||||
'\0', NULL, N_("Reject input files whose architecture is unknown"),
|
||||
TWO_DASHES },
|
||||
- { {"add-needed", no_argument, NULL, OPTION_ADD_NEEDED},
|
||||
- '\0', NULL, N_("Set DT_NEEDED tags for DT_NEEDED entries in\n"
|
||||
- " following dynamic libs"),
|
||||
- TWO_DASHES },
|
||||
- { {"no-add-needed", no_argument, NULL, OPTION_NO_ADD_NEEDED},
|
||||
- '\0', NULL, N_("Do not set DT_NEEDED tags for DT_NEEDED entries\n"
|
||||
- " in following dynamic libs"),
|
||||
- TWO_DASHES },
|
||||
- { {"as-needed", no_argument, NULL, OPTION_AS_NEEDED},
|
||||
+
|
||||
+ /* The next two options are deprecated because of their similarity to
|
||||
+ --as-needed and --no-as-needed. They have been replaced by
|
||||
+ --resolve-implicit-dynamic-symbols and
|
||||
+ --no-resolve-implicit-dynamic-symbols. */
|
||||
+ { {"add-needed", no_argument, NULL, OPTION_ADD_DT_NEEDED_FOR_DYNAMIC},
|
||||
+ '\0', NULL, NULL, NO_HELP },
|
||||
+ { {"no-add-needed", no_argument, NULL, OPTION_NO_ADD_DT_NEEDED_FOR_DYNAMIC},
|
||||
+ '\0', NULL, NULL, NO_HELP },
|
||||
+
|
||||
+ { {"as-needed", no_argument, NULL, OPTION_ADD_DT_NEEDED_FOR_REGULAR},
|
||||
'\0', NULL, N_("Only set DT_NEEDED for following dynamic libs if used"),
|
||||
TWO_DASHES },
|
||||
- { {"no-as-needed", no_argument, NULL, OPTION_NO_AS_NEEDED},
|
||||
- '\0', NULL, N_("Always set DT_NEEDED for following dynamic libs"),
|
||||
+ { {"no-as-needed", no_argument, NULL, OPTION_NO_ADD_DT_NEEDED_FOR_REGULAR},
|
||||
+ '\0', NULL, N_("Always set DT_NEEDED for dynamic libraries mentioned on\n"
|
||||
+ " the command line"),
|
||||
TWO_DASHES },
|
||||
{ {"assert", required_argument, NULL, OPTION_ASSERT},
|
||||
'\0', N_("KEYWORD"), N_("Ignored for SunOS compatibility"), ONE_DASH },
|
||||
@@ -373,6 +376,15 @@ static const struct ld_option ld_options
|
||||
{ {"no-check-sections", no_argument, NULL, OPTION_NO_CHECK_SECTIONS},
|
||||
'\0', NULL, N_("Do not check section addresses for overlaps"),
|
||||
TWO_DASHES },
|
||||
+ { {"copy-dt-needed-entries", no_argument, NULL,
|
||||
+ OPTION_ADD_DT_NEEDED_FOR_DYNAMIC},
|
||||
+ '\0', NULL, N_("Copy DT_NEEDED links mentioned inside DSOs that follow"),
|
||||
+ TWO_DASHES },
|
||||
+ { {"no-copy-dt-needed-entries", no_argument, NULL,
|
||||
+ OPTION_NO_ADD_DT_NEEDED_FOR_DYNAMIC},
|
||||
+ '\0', NULL, N_("Do not copy DT_NEEDED links mentioned inside DSOs that follow"),
|
||||
+ TWO_DASHES },
|
||||
+
|
||||
{ {"cref", no_argument, NULL, OPTION_CREF},
|
||||
'\0', NULL, N_("Output cross reference table"), TWO_DASHES },
|
||||
{ {"defsym", required_argument, NULL, OPTION_DEFSYM},
|
||||
@@ -1373,17 +1385,17 @@ parse_args (unsigned argc, char **argv)
|
||||
case OPTION_WHOLE_ARCHIVE:
|
||||
whole_archive = TRUE;
|
||||
break;
|
||||
- case OPTION_ADD_NEEDED:
|
||||
- add_needed = TRUE;
|
||||
+ case OPTION_ADD_DT_NEEDED_FOR_DYNAMIC:
|
||||
+ add_DT_NEEDED_for_dynamic = TRUE;
|
||||
break;
|
||||
- case OPTION_NO_ADD_NEEDED:
|
||||
- add_needed = FALSE;
|
||||
+ case OPTION_NO_ADD_DT_NEEDED_FOR_DYNAMIC:
|
||||
+ add_DT_NEEDED_for_dynamic = FALSE;
|
||||
break;
|
||||
- case OPTION_AS_NEEDED:
|
||||
- as_needed = TRUE;
|
||||
+ case OPTION_ADD_DT_NEEDED_FOR_REGULAR:
|
||||
+ add_DT_NEEDED_for_regular = TRUE;
|
||||
break;
|
||||
- case OPTION_NO_AS_NEEDED:
|
||||
- as_needed = FALSE;
|
||||
+ case OPTION_NO_ADD_DT_NEEDED_FOR_REGULAR:
|
||||
+ add_DT_NEEDED_for_regular = FALSE;
|
||||
break;
|
||||
case OPTION_WRAP:
|
||||
add_wrap (optarg);
|
||||
diff -rup ../binutils-2.20.51.0.2/ld/NEWS ./ld/NEWS
|
||||
--- ../binutils-2.20.51.0.2/ld/NEWS 2010-01-20 08:27:18.000000000 +0000
|
||||
+++ ./ld/NEWS 2010-01-13 16:01:16.000000000 +0000
|
||||
@@ -1,5 +1,8 @@
|
||||
-*- text -*-
|
||||
|
||||
+* --add-needed renamed to --copy-dt-needed-entries in order to avoid confusion
|
||||
+ with --as-needed option.
|
||||
+
|
||||
* Add support for the Renesas RX processor.
|
||||
|
||||
Changes in 2.20:
|
@ -1,38 +1,51 @@
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/elfcode.h 2009-10-12 11:45:05.000000000 +0100
|
||||
+++ bfd/elfcode.h 2009-10-12 11:47:14.000000000 +0100
|
||||
@@ -1175,6 +1175,24 @@ elf_checksum_contents (bfd *abfd,
|
||||
|
||||
if (i_shdr.contents)
|
||||
(*process) (i_shdr.contents, i_shdr.sh_size, arg);
|
||||
+ else
|
||||
+ {
|
||||
+ asection *sec;
|
||||
+
|
||||
+ sec = bfd_section_from_elf_index (abfd, count);
|
||||
+ if (sec != NULL)
|
||||
+ {
|
||||
+ if (sec->contents == NULL)
|
||||
+ {
|
||||
+ /* Force rereading from file. */
|
||||
+ sec->flags &= ~SEC_IN_MEMORY;
|
||||
+ if (! bfd_malloc_and_get_section (abfd, sec, & sec->contents))
|
||||
+ continue;
|
||||
+ }
|
||||
+ if (sec->contents != NULL)
|
||||
+ (*process) (sec->contents, i_shdr.sh_size, arg);
|
||||
+ }
|
||||
+ }
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/section.c 2009-10-12 11:45:05.000000000 +0100
|
||||
+++ bfd/section.c 2009-10-12 11:48:44.000000000 +0100
|
||||
@@ -1553,7 +1553,7 @@ bfd_malloc_and_get_section (bfd *abfd, s
|
||||
return TRUE;
|
||||
|
||||
p = (bfd_byte *)
|
||||
- bfd_malloc (sec->rawsize > sec->size ? sec->rawsize : sec->size);
|
||||
+ bfd_zmalloc (sec->rawsize > sec->size ? sec->rawsize : sec->size);
|
||||
if (p == NULL)
|
||||
return FALSE;
|
||||
*buf = p;
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/elfcode.h ./bfd/elfcode.h
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/elfcode.h 2010-04-08 15:29:32.000000000 +0100
|
||||
--- ./bfd/elfcode.h 2010-04-08 15:29:39.000000000 +0100
|
||||
*************** elf_checksum_contents (bfd *abfd,
|
||||
*** 1188,1193 ****
|
||||
--- 1188,1211 ----
|
||||
|
||||
if (i_shdr.contents)
|
||||
(*process) (i_shdr.contents, i_shdr.sh_size, arg);
|
||||
+ else
|
||||
+ {
|
||||
+ asection *sec;
|
||||
+
|
||||
+ sec = bfd_section_from_elf_index (abfd, count);
|
||||
+ if (sec != NULL)
|
||||
+ {
|
||||
+ if (sec->contents == NULL)
|
||||
+ {
|
||||
+ /* Force rereading from file. */
|
||||
+ sec->flags &= ~SEC_IN_MEMORY;
|
||||
+ if (! bfd_malloc_and_get_section (abfd, sec, & sec->contents))
|
||||
+ continue;
|
||||
+ }
|
||||
+ if (sec->contents != NULL)
|
||||
+ (*process) (sec->contents, i_shdr.sh_size, arg);
|
||||
+ }
|
||||
+ }
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/section.c ./bfd/section.c
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/section.c 2010-04-08 15:29:32.000000000 +0100
|
||||
--- ./bfd/section.c 2010-04-08 15:29:39.000000000 +0100
|
||||
*************** bfd_malloc_and_get_section (bfd *abfd, s
|
||||
*** 1488,1494 ****
|
||||
return TRUE;
|
||||
|
||||
p = (bfd_byte *)
|
||||
! bfd_malloc (sec->rawsize > sec->size ? sec->rawsize : sec->size);
|
||||
if (p == NULL)
|
||||
return FALSE;
|
||||
*buf = p;
|
||||
--- 1488,1494 ----
|
||||
return TRUE;
|
||||
|
||||
p = (bfd_byte *)
|
||||
! bfd_zmalloc (sec->rawsize > sec->size ? sec->rawsize : sec->size);
|
||||
if (p == NULL)
|
||||
return FALSE;
|
||||
*buf = p;
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/section.c.orig ./bfd/section.c.orig
|
||||
|
@ -1,139 +0,0 @@
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/bfd/ChangeLog bfd/ChangeLog
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/bfd/ChangeLog 2010-03-04 09:15:22.000000000 +0000
|
||||
--- bfd/ChangeLog 2010-03-04 10:37:24.000000000 +0000
|
||||
***************
|
||||
*** 1,3 ****
|
||||
--- 1,11 ----
|
||||
+ 2010-02-18 H.J. Lu <hongjiu.lu@intel.com>
|
||||
+
|
||||
+ * elf32-i386.c (elf_i386_add_symbol_hook): Don't set
|
||||
+ has_ifunc_symbols if the symbol comes from a shared library.
|
||||
+ * elf32-ppc.c (ppc_elf_add_symbol_hook): Likewise.
|
||||
+ * elf64-ppc.c (ppc64_elf_add_symbol_hook): Likewise.
|
||||
+ * elf64-x86-64.c (elf64_x86_64_add_symbol_hook): Likewise.
|
||||
+
|
||||
2009-12-17 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
PR ld/11088
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/bfd/elf32-i386.c bfd/elf32-i386.c
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/bfd/elf32-i386.c 2010-03-04 09:15:19.000000000 +0000
|
||||
--- bfd/elf32-i386.c 2010-03-04 10:37:39.000000000 +0000
|
||||
*************** elf_i386_add_symbol_hook (bfd * abfd ATT
|
||||
*** 4613,4619 ****
|
||||
asection ** secp ATTRIBUTE_UNUSED,
|
||||
bfd_vma * valp ATTRIBUTE_UNUSED)
|
||||
{
|
||||
! if (ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
|
||||
elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
|
||||
return _bfd_elf_add_sharable_symbol (abfd, info, sym, namep, flagsp,
|
||||
--- 4613,4620 ----
|
||||
asection ** secp ATTRIBUTE_UNUSED,
|
||||
bfd_vma * valp ATTRIBUTE_UNUSED)
|
||||
{
|
||||
! if ((abfd->flags & DYNAMIC) == 0
|
||||
! && ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
|
||||
elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
|
||||
return _bfd_elf_add_sharable_symbol (abfd, info, sym, namep, flagsp,
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/bfd/elf32-ppc.c bfd/elf32-ppc.c
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/bfd/elf32-ppc.c 2010-03-04 09:15:20.000000000 +0000
|
||||
--- bfd/elf32-ppc.c 2010-03-04 10:38:02.000000000 +0000
|
||||
*************** ppc_elf_add_symbol_hook (bfd *abfd,
|
||||
*** 3133,3139 ****
|
||||
*valp = sym->st_size;
|
||||
}
|
||||
|
||||
! if (ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
|
||||
elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
|
||||
return TRUE;
|
||||
--- 3133,3140 ----
|
||||
*valp = sym->st_size;
|
||||
}
|
||||
|
||||
! if ((abfd->flags & DYNAMIC) == 0
|
||||
! && ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
|
||||
elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
|
||||
return TRUE;
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/bfd/elf64-ppc.c bfd/elf64-ppc.c
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/bfd/elf64-ppc.c 2010-03-04 09:15:20.000000000 +0000
|
||||
--- bfd/elf64-ppc.c 2010-03-04 10:38:32.000000000 +0000
|
||||
*************** ppc64_elf_add_symbol_hook (bfd *ibfd ATT
|
||||
*** 4531,4537 ****
|
||||
bfd_vma *value ATTRIBUTE_UNUSED)
|
||||
{
|
||||
if (ELF_ST_TYPE (isym->st_info) == STT_GNU_IFUNC)
|
||||
! elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
else if (ELF_ST_TYPE (isym->st_info) == STT_FUNC)
|
||||
;
|
||||
else if (*sec != NULL
|
||||
--- 4531,4540 ----
|
||||
bfd_vma *value ATTRIBUTE_UNUSED)
|
||||
{
|
||||
if (ELF_ST_TYPE (isym->st_info) == STT_GNU_IFUNC)
|
||||
! {
|
||||
! if ((ibfd->flags & DYNAMIC) == 0)
|
||||
! elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
! }
|
||||
else if (ELF_ST_TYPE (isym->st_info) == STT_FUNC)
|
||||
;
|
||||
else if (*sec != NULL
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/bfd/elf64-x86-64.c bfd/elf64-x86-64.c
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/bfd/elf64-x86-64.c 2010-03-04 09:15:21.000000000 +0000
|
||||
--- bfd/elf64-x86-64.c 2010-03-04 10:38:50.000000000 +0000
|
||||
*************** elf64_x86_64_add_symbol_hook (bfd *abfd,
|
||||
*** 4242,4248 ****
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
! if (ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
|
||||
elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
|
||||
return _bfd_elf_add_sharable_symbol (abfd, info, sym, namep, flagsp,
|
||||
--- 4242,4249 ----
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
! if ((abfd->flags & DYNAMIC) == 0
|
||||
! && ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
|
||||
elf_tdata (info->output_bfd)->has_ifunc_symbols = TRUE;
|
||||
|
||||
return _bfd_elf_add_sharable_symbol (abfd, info, sym, namep, flagsp,
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/ld/testsuite/ChangeLog ld/testsuite/ChangeLog
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/ld/testsuite/ChangeLog 2010-03-04 09:16:17.000000000 +0000
|
||||
--- ld/testsuite/ChangeLog 2010-03-04 11:43:29.000000000 +0000
|
||||
***************
|
||||
*** 1,3 ****
|
||||
--- 1,8 ----
|
||||
+ 2010-02-18 H.J. Lu <hongjiu.lu@intel.com>
|
||||
+
|
||||
+ * ld-ifunc/ifunc.exp: Expect System V OSABI in dynamic
|
||||
+ ifunc-using executable.
|
||||
+
|
||||
2009-10-09 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR ld/10749
|
||||
diff -rcp ../binutils-2.20.51.0.2.copy-patched/ld/testsuite/ld-ifunc/ifunc.exp ld/testsuite/ld-ifunc/ifunc.exp
|
||||
*** ../binutils-2.20.51.0.2.copy-patched/ld/testsuite/ld-ifunc/ifunc.exp 2010-03-04 09:16:08.000000000 +0000
|
||||
--- ld/testsuite/ld-ifunc/ifunc.exp 2010-03-04 11:44:15.000000000 +0000
|
||||
*************** if {! [check_osabi tmpdir/static_prog {U
|
||||
*** 257,264 ****
|
||||
fail "Static ifunc-using executable does not have an OS/ABI field of LINUX"
|
||||
set fails [expr $fails + 1]
|
||||
}
|
||||
! if {! [check_osabi tmpdir/dynamic_prog {UNIX - Linux}]} {
|
||||
! fail "Dynamic ifunc-using executable does not have an OS/ABI field of LINUX"
|
||||
set fails [expr $fails + 1]
|
||||
}
|
||||
if {! [check_osabi tmpdir/static_nonifunc_prog {UNIX - System V}]} {
|
||||
--- 257,264 ----
|
||||
fail "Static ifunc-using executable does not have an OS/ABI field of LINUX"
|
||||
set fails [expr $fails + 1]
|
||||
}
|
||||
! if {! [check_osabi tmpdir/dynamic_prog {UNIX - System V}]} {
|
||||
! fail "Dynamic ifunc-using executable does not have an OS/ABI field of System V"
|
||||
set fails [expr $fails + 1]
|
||||
}
|
||||
if {! [check_osabi tmpdir/static_nonifunc_prog {UNIX - System V}]} {
|
@ -1,464 +0,0 @@
|
||||
diff -rup ../binutils-2.20.51.0.2.original/ChangeLog ./ChangeLog
|
||||
--- ../binutils-2.20.51.0.2.original/ChangeLog 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./ChangeLog 2009-11-12 16:32:00.000000000 +0000
|
||||
@@ -1,3 +1,9 @@
|
||||
+2009-10-15 Roland McGrath <roland@redhat.com>
|
||||
+
|
||||
+ * configure.ac (--enable-gold): Accept --enable-gold=both to
|
||||
+ add gold to configdirs without removing ld.
|
||||
+ * configure: Regenerated.
|
||||
+
|
||||
2009-10-06 Ian Lance Taylor <iant@google.com>
|
||||
|
||||
* Makefile.def: check-gold depends upon all-gas.
|
||||
diff -rup ../binutils-2.20.51.0.2.original/configure ./configure
|
||||
--- ../binutils-2.20.51.0.2.original/configure 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./configure 2009-11-12 16:38:13.000000000 +0000
|
||||
@@ -3076,7 +3076,8 @@ else
|
||||
ENABLE_GOLD=no
|
||||
fi
|
||||
|
||||
-if test "${ENABLE_GOLD}" = "yes"; then
|
||||
+case "${ENABLE_GOLD}" in
|
||||
+yes|both)
|
||||
# Check for ELF target.
|
||||
is_elf=no
|
||||
case "${target}" in
|
||||
@@ -3096,11 +3097,18 @@ if test "${ENABLE_GOLD}" = "yes"; then
|
||||
# Check for target supported by gold.
|
||||
case "${target}" in
|
||||
i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-*)
|
||||
- configdirs="`echo " ${configdirs} " | sed -e 's/ ld / gold /'`"
|
||||
+ if test "${ENABLE_GOLD}" = both; then
|
||||
+ configdirs="$configdirs gold"
|
||||
+ else
|
||||
+ configdirs="`echo " ${configdirs} " | sed -e 's/ ld / gold /'`"
|
||||
+ fi
|
||||
+
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
-fi
|
||||
+ ENABLE_GOLD=yes
|
||||
+ ;;
|
||||
+esac
|
||||
|
||||
# Configure extra directories which are host specific
|
||||
|
||||
diff -rup ../binutils-2.20.51.0.2.original/configure.ac ./configure.ac
|
||||
--- ../binutils-2.20.51.0.2.original/configure.ac 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./configure.ac 2009-11-12 16:38:08.000000000 +0000
|
||||
@@ -314,7 +314,8 @@ AC_ARG_ENABLE(gold,
|
||||
[ --enable-gold use gold instead of ld],
|
||||
ENABLE_GOLD=$enableval,
|
||||
ENABLE_GOLD=no)
|
||||
-if test "${ENABLE_GOLD}" = "yes"; then
|
||||
+case "${ENABLE_GOLD}" in
|
||||
+yes|both)
|
||||
# Check for ELF target.
|
||||
is_elf=no
|
||||
case "${target}" in
|
||||
@@ -334,11 +335,18 @@ if test "${ENABLE_GOLD}" = "yes"; then
|
||||
# Check for target supported by gold.
|
||||
case "${target}" in
|
||||
i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-*)
|
||||
- configdirs="`echo " ${configdirs} " | sed -e 's/ ld / gold /'`"
|
||||
+ if test "${ENABLE_GOLD}" = both; then
|
||||
+ configdirs="$configdirs gold"
|
||||
+ else
|
||||
+ configdirs="`echo " ${configdirs} " | sed -e 's/ ld / gold /'`"
|
||||
+ fi
|
||||
+
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
-fi
|
||||
+ ENABLE_GOLD=yes
|
||||
+ ;;
|
||||
+esac
|
||||
|
||||
# Configure extra directories which are host specific
|
||||
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gold/ChangeLog ./gold/ChangeLog
|
||||
--- ../binutils-2.20.51.0.2.original/gold/ChangeLog 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./gold/ChangeLog 2009-11-12 16:32:17.000000000 +0000
|
||||
@@ -1,3 +1,11 @@
|
||||
+2009-10-15 Roland McGrath <roland@redhat.com>
|
||||
+
|
||||
+ * configure.ac (ld_name): New substituted variable.
|
||||
+ Under --enable-gold=both, set it to ld.gold, else to ld.
|
||||
+ * configure: Regenerated.
|
||||
+ * Makefile.am (install-exec-local): Use @ld_name@.
|
||||
+ * Makefile.in: Regenerated.
|
||||
+
|
||||
2009-10-07 Viktor Kutuzov <vkutuzov@accesssoftek.com>
|
||||
|
||||
* arm.cc (Arm_relocate_functions::extract_arm_movw_movt_addend):
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gold/configure ./gold/configure
|
||||
--- ../binutils-2.20.51.0.2.original/gold/configure 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./gold/configure 2009-11-12 16:37:17.000000000 +0000
|
||||
@@ -682,6 +682,7 @@ PLUGINS_FALSE
|
||||
PLUGINS_TRUE
|
||||
THREADS_FALSE
|
||||
THREADS_TRUE
|
||||
+ld_name
|
||||
am__untar
|
||||
am__tar
|
||||
AMTAR
|
||||
@@ -759,6 +760,7 @@ ac_subst_files=''
|
||||
ac_user_opts='
|
||||
enable_option_checking
|
||||
with_sysroot
|
||||
+enable_gold
|
||||
enable_threads
|
||||
enable_plugins
|
||||
enable_targets
|
||||
@@ -1403,6 +1405,7 @@ Optional Features:
|
||||
--disable-option-checking ignore unrecognized --enable/--with options
|
||||
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
|
||||
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
|
||||
+ --enable-gold building BFD ld too, install as ld.gold
|
||||
--enable-threads multi-threaded linking
|
||||
--enable-plugins linker plugins
|
||||
--enable-targets alternative target configurations
|
||||
@@ -3227,6 +3230,14 @@ cat >>confdefs.h <<_ACEOF
|
||||
_ACEOF
|
||||
|
||||
|
||||
+ld_name=ld
|
||||
+# Check whether --enable-gold was given.
|
||||
+if test "${enable_gold+set}" = set; then :
|
||||
+ enableval=$enable_gold; test "x${enableval}" != xboth || ld_name=ld.gold
|
||||
+fi
|
||||
+
|
||||
+
|
||||
+
|
||||
# Check whether --enable-threads was given.
|
||||
if test "${enable_threads+set}" = set; then :
|
||||
enableval=$enable_threads; case "${enableval}" in
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gold/configure.ac ./gold/configure.ac
|
||||
--- ../binutils-2.20.51.0.2.original/gold/configure.ac 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./gold/configure.ac 2009-11-12 16:35:21.000000000 +0000
|
||||
@@ -38,6 +38,12 @@ AC_DEFINE_UNQUOTED(TARGET_SYSTEM_ROOT, "
|
||||
AC_DEFINE_UNQUOTED(TARGET_SYSTEM_ROOT_RELOCATABLE, $sysroot_relocatable,
|
||||
[Whether the system root can be relocated])
|
||||
|
||||
+ld_name=ld
|
||||
+AC_ARG_ENABLE(gold,
|
||||
+[ --enable-gold building BFD ld too, install as ld.gold],
|
||||
+[test "x${enableval}" != xboth || ld_name=ld.gold])
|
||||
+AC_SUBST(ld_name)
|
||||
+
|
||||
dnl For now threads are a configure time option.
|
||||
AC_ARG_ENABLE([threads],
|
||||
[ --enable-threads multi-threaded linking],
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gold/Makefile.am ./gold/Makefile.am
|
||||
--- ../binutils-2.20.51.0.2.original/gold/Makefile.am 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ ./gold/Makefile.am 2009-11-12 16:34:29.000000000 +0000
|
||||
@@ -163,7 +163,7 @@ check: libgold.a
|
||||
|
||||
install-exec-local: ld-new$(EXEEXT)
|
||||
$(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(tooldir)/bin
|
||||
- n=`echo ld | sed '$(transform)'`; \
|
||||
+ n=`echo @ld_name@ | sed '$(transform)'`; \
|
||||
$(INSTALL_PROGRAM) ld-new$(EXEEXT) $(DESTDIR)$(bindir)/$${n}$(EXEEXT); \
|
||||
if test "$(bindir)" != "$(tooldir)/bin"; then \
|
||||
rm -f $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
|
||||
diff -rup ../binutils-2.20.51.0.2.original/ld/ChangeLog ./ld/ChangeLog
|
||||
--- ../binutils-2.20.51.0.2.original/ld/ChangeLog 2009-11-12 16:31:13.000000000 +0000
|
||||
+++ ./ld/ChangeLog 2009-11-12 16:32:27.000000000 +0000
|
||||
@@ -1,3 +1,13 @@
|
||||
+2009-10-15 Roland McGrath <roland@redhat.com>
|
||||
+
|
||||
+ * configure.ac (ld_name): New substituted variable.
|
||||
+ Under --enable-gold, set it to ld.bfd, else to ld.
|
||||
+ * configure: Regenerated.
|
||||
+ * Makefile.am (transform): Use @ld_name@.
|
||||
+ (install-exec-local): Likewise.
|
||||
+ If it's not ld, install an ld symlink to it.
|
||||
+ * Makefile.in: Regenerated.
|
||||
+
|
||||
2009-10-09 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
PR ld/10749
|
||||
diff -rup ../binutils-2.20.51.0.2.original/ld/configure ./ld/configure
|
||||
--- ../binutils-2.20.51.0.2.original/ld/configure 2009-11-12 16:31:12.000000000 +0000
|
||||
+++ ./ld/configure 2009-11-12 16:37:09.000000000 +0000
|
||||
@@ -797,6 +797,7 @@ GREP
|
||||
CPP
|
||||
NO_WERROR
|
||||
WARN_CFLAGS
|
||||
+ld_name
|
||||
TARGET_SYSTEM_ROOT_DEFINE
|
||||
TARGET_SYSTEM_ROOT
|
||||
use_sysroot
|
||||
@@ -901,6 +902,7 @@ with_lib_path
|
||||
enable_targets
|
||||
enable_64_bit_bfd
|
||||
with_sysroot
|
||||
+enable_gold
|
||||
enable_got
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
@@ -1548,6 +1550,7 @@ Optional Features:
|
||||
(and sometimes confusing) to the casual installer
|
||||
--enable-targets alternative target configurations
|
||||
--enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
|
||||
+ --enable-gold building gold too, install as ld.bfd
|
||||
--enable-got=<type> GOT handling scheme (target, single, negative,
|
||||
multigot)
|
||||
--enable-werror treat compile warnings as errors
|
||||
@@ -4302,6 +4305,15 @@ fi
|
||||
|
||||
|
||||
|
||||
+ld_name=ld
|
||||
+# Check whether --enable-gold was given.
|
||||
+if test "${enable_gold+set}" = set; then :
|
||||
+ enableval=$enable_gold; case "${enableval}" in
|
||||
+ yes|both) ld_name=ld.bfd
|
||||
+esac
|
||||
+fi
|
||||
+
|
||||
+
|
||||
# Check whether --enable-got was given.
|
||||
if test "${enable_got+set}" = set; then :
|
||||
enableval=$enable_got; case "${enableval}" in
|
||||
@@ -6087,13 +6099,13 @@ if test "${lt_cv_nm_interface+set}" = se
|
||||
else
|
||||
lt_cv_nm_interface="BSD nm"
|
||||
echo "int some_variable = 0;" > conftest.$ac_ext
|
||||
- (eval echo "\"\$as_me:6090: $ac_compile\"" >&5)
|
||||
+ (eval echo "\"\$as_me:6102: $ac_compile\"" >&5)
|
||||
(eval "$ac_compile" 2>conftest.err)
|
||||
cat conftest.err >&5
|
||||
- (eval echo "\"\$as_me:6093: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
|
||||
+ (eval echo "\"\$as_me:6105: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
|
||||
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
|
||||
cat conftest.err >&5
|
||||
- (eval echo "\"\$as_me:6096: output\"" >&5)
|
||||
+ (eval echo "\"\$as_me:6108: output\"" >&5)
|
||||
cat conftest.out >&5
|
||||
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
|
||||
lt_cv_nm_interface="MS dumpbin"
|
||||
@@ -7298,7 +7310,7 @@ ia64-*-hpux*)
|
||||
;;
|
||||
*-*-irix6*)
|
||||
# Find out which ABI we are using.
|
||||
- echo '#line 7301 "configure"' > conftest.$ac_ext
|
||||
+ echo '#line 7313 "configure"' > conftest.$ac_ext
|
||||
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
|
||||
(eval $ac_compile) 2>&5
|
||||
ac_status=$?
|
||||
@@ -8560,11 +8572,11 @@ else
|
||||
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
|
||||
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
|
||||
-e 's:$: $lt_compiler_flag:'`
|
||||
- (eval echo "\"\$as_me:8563: $lt_compile\"" >&5)
|
||||
+ (eval echo "\"\$as_me:8575: $lt_compile\"" >&5)
|
||||
(eval "$lt_compile" 2>conftest.err)
|
||||
ac_status=$?
|
||||
cat conftest.err >&5
|
||||
- echo "$as_me:8567: \$? = $ac_status" >&5
|
||||
+ echo "$as_me:8579: \$? = $ac_status" >&5
|
||||
if (exit $ac_status) && test -s "$ac_outfile"; then
|
||||
# The compiler can only warn and ignore the option if not recognized
|
||||
# So say no if there are warnings other than the usual output.
|
||||
@@ -8899,11 +8911,11 @@ else
|
||||
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
|
||||
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
|
||||
-e 's:$: $lt_compiler_flag:'`
|
||||
- (eval echo "\"\$as_me:8902: $lt_compile\"" >&5)
|
||||
+ (eval echo "\"\$as_me:8914: $lt_compile\"" >&5)
|
||||
(eval "$lt_compile" 2>conftest.err)
|
||||
ac_status=$?
|
||||
cat conftest.err >&5
|
||||
- echo "$as_me:8906: \$? = $ac_status" >&5
|
||||
+ echo "$as_me:8918: \$? = $ac_status" >&5
|
||||
if (exit $ac_status) && test -s "$ac_outfile"; then
|
||||
# The compiler can only warn and ignore the option if not recognized
|
||||
# So say no if there are warnings other than the usual output.
|
||||
@@ -9004,11 +9016,11 @@ else
|
||||
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
|
||||
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
|
||||
-e 's:$: $lt_compiler_flag:'`
|
||||
- (eval echo "\"\$as_me:9007: $lt_compile\"" >&5)
|
||||
+ (eval echo "\"\$as_me:9019: $lt_compile\"" >&5)
|
||||
(eval "$lt_compile" 2>out/conftest.err)
|
||||
ac_status=$?
|
||||
cat out/conftest.err >&5
|
||||
- echo "$as_me:9011: \$? = $ac_status" >&5
|
||||
+ echo "$as_me:9023: \$? = $ac_status" >&5
|
||||
if (exit $ac_status) && test -s out/conftest2.$ac_objext
|
||||
then
|
||||
# The compiler can only warn and ignore the option if not recognized
|
||||
@@ -9059,11 +9071,11 @@ else
|
||||
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
|
||||
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
|
||||
-e 's:$: $lt_compiler_flag:'`
|
||||
- (eval echo "\"\$as_me:9062: $lt_compile\"" >&5)
|
||||
+ (eval echo "\"\$as_me:9074: $lt_compile\"" >&5)
|
||||
(eval "$lt_compile" 2>out/conftest.err)
|
||||
ac_status=$?
|
||||
cat out/conftest.err >&5
|
||||
- echo "$as_me:9066: \$? = $ac_status" >&5
|
||||
+ echo "$as_me:9078: \$? = $ac_status" >&5
|
||||
if (exit $ac_status) && test -s out/conftest2.$ac_objext
|
||||
then
|
||||
# The compiler can only warn and ignore the option if not recognized
|
||||
@@ -10811,11 +10823,11 @@ fi
|
||||
case "$host_cpu" in
|
||||
x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
echo 'int i;' > conftest.$ac_ext
|
||||
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
|
||||
(eval $ac_compile) 2>&5
|
||||
ac_status=$?
|
||||
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
- (exit $ac_status); }; then
|
||||
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
+ test $ac_status = 0; }; then
|
||||
case `/usr/bin/file conftest.$ac_objext` in
|
||||
*64-bit*)
|
||||
libsuff=64
|
||||
@@ -11465,7 +11477,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
-#line 11444 "configure"
|
||||
+#line 11480 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@@ -11561,7 +11573,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
-#line 11540 "configure"
|
||||
+#line 11576 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
diff -rup ../binutils-2.20.51.0.2.original/ld/configure.in ./ld/configure.in
|
||||
--- ../binutils-2.20.51.0.2.original/ld/configure.in 2009-11-12 16:31:10.000000000 +0000
|
||||
+++ ./ld/configure.in 2009-11-12 16:36:40.000000000 +0000
|
||||
@@ -69,6 +69,14 @@ AC_SUBST(use_sysroot)
|
||||
AC_SUBST(TARGET_SYSTEM_ROOT)
|
||||
AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
|
||||
|
||||
+ld_name=ld
|
||||
+AC_ARG_ENABLE(gold,
|
||||
+[ --enable-gold building gold too, install as ld.bfd],
|
||||
+[case "${enableval}" in
|
||||
+ yes|both) ld_name=ld.bfd
|
||||
+esac])dnl
|
||||
+AC_SUBST(ld_name)
|
||||
+
|
||||
AC_ARG_ENABLE([got],
|
||||
AS_HELP_STRING([--enable-got=<type>],
|
||||
[GOT handling scheme (target, single, negative, multigot)]),
|
||||
diff -rup ../binutils-2.20.51.0.2.original/ld/Makefile.am ./ld/Makefile.am
|
||||
--- ../binutils-2.20.51.0.2.original/ld/Makefile.am 2009-11-12 16:31:10.000000000 +0000
|
||||
+++ ./ld/Makefile.am 2009-11-12 16:36:20.000000000 +0000
|
||||
@@ -96,7 +96,7 @@ CXX_FOR_TARGET = ` \
|
||||
fi; \
|
||||
fi`
|
||||
|
||||
-transform = s/^ld-new$$/ld/;@program_transform_name@
|
||||
+transform = s/^ld-new$$/@ld_name@/;$(program_transform_name)
|
||||
bin_PROGRAMS = ld-new
|
||||
info_TEXINFOS = ld.texinfo
|
||||
ld_TEXINFOS = configdoc.texi
|
||||
@@ -199,7 +199,7 @@ ALL_EMULATIONS = \
|
||||
eelf32mcore.o \
|
||||
eelf32mep.o \
|
||||
eelf32mb_linux.o \
|
||||
- eelf32microblaze.o \
|
||||
+ eelf32microblaze.o \
|
||||
eelf32mipswindiss.o \
|
||||
eelf32mt.o \
|
||||
eelf32openrisc.o \
|
||||
@@ -1962,8 +1962,11 @@ CLEANFILES = dep.sed DEP DEPA DEP1 DEP2
|
||||
.PHONY: install-exec-local install-data-local
|
||||
|
||||
install-exec-local: ld-new$(EXEEXT)
|
||||
+ [ @ld_name@ = ld ] || \
|
||||
+ (cd $(DESTDIR)/$(bindir) && \
|
||||
+ $(LN_S) -f @ld_name@ `echo ld | sed '$(transform)'`)
|
||||
$(mkinstalldirs) $(DESTDIR)$(tooldir)/bin
|
||||
- n=`echo ld | sed '$(transform)'`; \
|
||||
+ n=`echo @ld_name@ | sed '$(transform)'`; \
|
||||
if [ "$(bindir)/$$n$(EXEEXT)" != "$(tooldir)/bin/ld$(EXEEXT)" ]; then \
|
||||
rm -f $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
|
||||
ln $(DESTDIR)$(bindir)/$$n$(EXEEXT) $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT) >/dev/null 2>/dev/null \
|
||||
--- ../binutils-2.20.51.0.2.original/ld/Makefile.in 2009-11-12 16:31:13.000000000 +0000
|
||||
+++ ld/Makefile.in 2009-11-16 09:37:16.000000000 +0000
|
||||
@@ -149,10 +149,9 @@ AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGE
|
||||
$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS
|
||||
ETAGS = etags
|
||||
CTAGS = ctags
|
||||
-DEJATOOL = $(PACKAGE)
|
||||
RUNTESTDEFAULTFLAGS = --tool $$tool --srcdir $$srcdir
|
||||
DIST_SUBDIRS = $(SUBDIRS)
|
||||
-transform = s/^ld-new$$/ld/;@program_transform_name@
|
||||
+transform = s/^ld-new$$/@ld_name@/;$(program_transform_name)
|
||||
ACLOCAL = @ACLOCAL@
|
||||
AMTAR = @AMTAR@
|
||||
AR = @AR@
|
||||
@@ -293,6 +292,7 @@ htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
+ld_name = @ld_name@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
@@ -318,6 +318,7 @@ top_build_prefix = @top_build_prefix@
|
||||
top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
use_sysroot = @use_sysroot@
|
||||
+DEJATOOL = ld
|
||||
AUTOMAKE_OPTIONS = dejagnu no-texinfo.tex no-dist foreign
|
||||
ACLOCAL_AMFLAGS = -I .. -I ../config -I ../bfd
|
||||
TEXINFO_TEX = $(top_srcdir)/../texinfo/texinfo.tex
|
||||
@@ -484,7 +485,7 @@ ALL_EMULATIONS = \
|
||||
eelf32mcore.o \
|
||||
eelf32mep.o \
|
||||
eelf32mb_linux.o \
|
||||
- eelf32microblaze.o \
|
||||
+ eelf32microblaze.o \
|
||||
eelf32mipswindiss.o \
|
||||
eelf32mt.o \
|
||||
eelf32openrisc.o \
|
||||
@@ -3276,8 +3277,11 @@ mostlyclean-local:
|
||||
.PHONY: install-exec-local install-data-local
|
||||
|
||||
install-exec-local: ld-new$(EXEEXT)
|
||||
+ [ @ld_name@ = ld ] || \
|
||||
+ (cd $(DESTDIR)/$(bindir) && \
|
||||
+ $(LN_S) -f @ld_name@ `echo ld | sed '$(transform)'`)
|
||||
$(mkinstalldirs) $(DESTDIR)$(tooldir)/bin
|
||||
- n=`echo ld | sed '$(transform)'`; \
|
||||
+ n=`echo @ld_name@ | sed '$(transform)'`; \
|
||||
if [ "$(bindir)/$$n$(EXEEXT)" != "$(tooldir)/bin/ld$(EXEEXT)" ]; then \
|
||||
rm -f $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
|
||||
ln $(DESTDIR)$(bindir)/$$n$(EXEEXT) $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT) >/dev/null 2>/dev/null \
|
||||
--- ../binutils-2.20.51.0.2.original/gold/Makefile.in 2009-11-12 16:31:17.000000000 +0000
|
||||
+++ gold/Makefile.in 2009-11-16 09:40:33.000000000 +0000
|
||||
@@ -303,6 +303,7 @@ htmldir = @htmldir@
|
||||
includedir = @includedir@
|
||||
infodir = @infodir@
|
||||
install_sh = @install_sh@
|
||||
+ld_name = @ld_name@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
localedir = @localedir@
|
||||
@@ -1200,7 +1201,7 @@ check: libgold.a
|
||||
|
||||
install-exec-local: ld-new$(EXEEXT)
|
||||
$(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(tooldir)/bin
|
||||
- n=`echo ld | sed '$(transform)'`; \
|
||||
+ n=`echo @ld_name@ | sed '$(transform)'`; \
|
||||
$(INSTALL_PROGRAM) ld-new$(EXEEXT) $(DESTDIR)$(bindir)/$${n}$(EXEEXT); \
|
||||
if test "$(bindir)" != "$(tooldir)/bin"; then \
|
||||
rm -f $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
|
@ -1,69 +1,91 @@
|
||||
--- ../binutils-2.20.51.0.2.orig/ld/ldmain.c 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ld/ldmain.c 2009-10-12 11:38:36.000000000 +0100
|
||||
@@ -256,14 +256,6 @@ main (int argc, char **argv)
|
||||
command_line.warn_search_mismatch = TRUE;
|
||||
command_line.check_section_addresses = -1;
|
||||
|
||||
- if (getenv ("LD_SYMBOLIC") != NULL)
|
||||
- command_line.symbolic = symbolic;
|
||||
- else if (getenv ("LD_SYMBOLIC_FUNCTIONS") != NULL)
|
||||
- command_line.symbolic = symbolic_functions;
|
||||
-
|
||||
- if (getenv ("LD_AS_NEEDED") != NULL)
|
||||
- as_needed = TRUE;
|
||||
-
|
||||
/* We initialize DEMANGLING based on the environment variable
|
||||
COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
|
||||
output of the linker, unless COLLECT_NO_DEMANGLE is set in the
|
||||
--- ../binutils-2.20.51.0.2.orig/ld/ld.texinfo 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ld/ld.texinfo 2009-10-12 11:38:36.000000000 +0100
|
||||
@@ -1140,10 +1140,7 @@ for a library that satisfies a symbol re
|
||||
which is undefined at the point that the library was linked, or, if
|
||||
the library is not found in the DT_NEEDED lists of other libraries
|
||||
linked up to that point, a reference from another dynamic library.
|
||||
-@option{--no-as-needed} restores the default behaviour. If the
|
||||
-environment variable @code{LD_AS_NEEDED} is set, the linker will
|
||||
-behave as if the @option{--as-needed} option is passed to the linker as
|
||||
-the first command line option.
|
||||
+@option{--no-as-needed} restores the default behaviour.
|
||||
|
||||
@kindex --add-needed
|
||||
@kindex --no-add-needed
|
||||
@@ -1207,21 +1204,14 @@ When creating a shared library, bind ref
|
||||
definition within the shared library, if any. Normally, it is possible
|
||||
for a program linked against a shared library to override the definition
|
||||
within the shared library. This option is only meaningful on ELF
|
||||
-platforms which support shared libraries. If @option{-Bsymbolic} is not
|
||||
-used when linking a shared library, the linker will also turn on this
|
||||
-option if the environment variable @code{LD_SYMBOLIC} is set.
|
||||
+platforms which support shared libraries.
|
||||
|
||||
@kindex -Bsymbolic-functions
|
||||
@item -Bsymbolic-functions
|
||||
When creating a shared library, bind references to global function
|
||||
symbols to the definition within the shared library, if any.
|
||||
This option is only meaningful on ELF platforms which support shared
|
||||
-libraries. If @option{-Bsymbolic-functions} is not used when linking a
|
||||
-shared library, the linker will also turn on this option if the
|
||||
-environment variable @code{LD_SYMBOLIC_FUNCTIONS} is set. When
|
||||
-both environment variables @code{LD_SYMBOLIC} and
|
||||
-@code{LD_SYMBOLIC_FUNCTIONS} are set, @code{LD_SYMBOLIC} will take
|
||||
-precedent.
|
||||
+libraries.
|
||||
|
||||
@kindex --dynamic-list=@var{dynamic-list-file}
|
||||
@item --dynamic-list=@var{dynamic-list-file}
|
||||
--- ../binutils-2.20.51.0.2.orig/ld/NEWS 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ld/NEWS 2009-10-12 11:38:36.000000000 +0100
|
||||
@@ -64,11 +64,6 @@ Changes in 2.20:
|
||||
For the switch --enable-runtime-pseudo-reloc it uses for 32-bit
|
||||
runtime pseudo relocation version one, for 64-bit the version two.
|
||||
|
||||
-* ELF: Support environment variable LD_AS_NEEDED for --as-needed.
|
||||
-
|
||||
-* ELF: Support environment variables, LD_SYMBOLIC for -Bsymbolic and
|
||||
- LD_SYMBOLIC_FUNCTIONS for -Bsymbolic-functions.
|
||||
-
|
||||
Changes in 2.19:
|
||||
|
||||
* Linker scripts support a new INSERT command that makes it easier to
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/ld/ldmain.c ./ld/ldmain.c
|
||||
*** ../binutils-2.20.51.0.7.original/ld/ldmain.c 2010-04-08 15:03:56.000000000 +0100
|
||||
--- ./ld/ldmain.c 2010-04-08 15:05:09.000000000 +0100
|
||||
*************** main (int argc, char **argv)
|
||||
*** 258,271 ****
|
||||
command_line.check_section_addresses = -1;
|
||||
command_line.disable_target_specific_optimizations = -1;
|
||||
|
||||
- if (getenv ("LD_SYMBOLIC") != NULL)
|
||||
- command_line.symbolic = symbolic;
|
||||
- else if (getenv ("LD_SYMBOLIC_FUNCTIONS") != NULL)
|
||||
- command_line.symbolic = symbolic_functions;
|
||||
-
|
||||
- if (getenv ("LD_AS_NEEDED") != NULL)
|
||||
- add_DT_NEEDED_for_regular = TRUE;
|
||||
-
|
||||
/* We initialize DEMANGLING based on the environment variable
|
||||
COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
|
||||
output of the linker, unless COLLECT_NO_DEMANGLE is set in the
|
||||
--- 258,263 ----
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/ld/ld.texinfo ./ld/ld.texinfo
|
||||
*** ../binutils-2.20.51.0.7.original/ld/ld.texinfo 2010-04-08 15:03:55.000000000 +0100
|
||||
--- ./ld/ld.texinfo 2010-04-08 15:05:55.000000000 +0100
|
||||
*************** their names to the @option{--as-needed}
|
||||
*** 1152,1161 ****
|
||||
options. They have been replaced by @option{--copy-dt-needed-entries}
|
||||
and @option{--no-copy-dt-needed-entries}.
|
||||
|
||||
- If the environment variable @code{LD_AS_NEEDED} is set, the linker
|
||||
- will behave as if the @option{--as-needed} option is passed to the
|
||||
- linker as the first command line option.
|
||||
-
|
||||
@kindex -assert @var{keyword}
|
||||
@item -assert @var{keyword}
|
||||
This option is ignored for SunOS compatibility.
|
||||
--- 1152,1157 ----
|
||||
*************** When creating a shared library, bind ref
|
||||
*** 1206,1226 ****
|
||||
definition within the shared library, if any. Normally, it is possible
|
||||
for a program linked against a shared library to override the definition
|
||||
within the shared library. This option is only meaningful on ELF
|
||||
! platforms which support shared libraries. If @option{-Bsymbolic} is not
|
||||
! used when linking a shared library, the linker will also turn on this
|
||||
! option if the environment variable @code{LD_SYMBOLIC} is set.
|
||||
|
||||
@kindex -Bsymbolic-functions
|
||||
@item -Bsymbolic-functions
|
||||
When creating a shared library, bind references to global function
|
||||
symbols to the definition within the shared library, if any.
|
||||
This option is only meaningful on ELF platforms which support shared
|
||||
! libraries. If @option{-Bsymbolic-functions} is not used when linking a
|
||||
! shared library, the linker will also turn on this option if the
|
||||
! environment variable @code{LD_SYMBOLIC_FUNCTIONS} is set. When
|
||||
! both environment variables @code{LD_SYMBOLIC} and
|
||||
! @code{LD_SYMBOLIC_FUNCTIONS} are set, @code{LD_SYMBOLIC} will take
|
||||
! precedent.
|
||||
|
||||
@kindex --dynamic-list=@var{dynamic-list-file}
|
||||
@item --dynamic-list=@var{dynamic-list-file}
|
||||
--- 1202,1215 ----
|
||||
definition within the shared library, if any. Normally, it is possible
|
||||
for a program linked against a shared library to override the definition
|
||||
within the shared library. This option is only meaningful on ELF
|
||||
! platforms which support shared libraries.
|
||||
|
||||
@kindex -Bsymbolic-functions
|
||||
@item -Bsymbolic-functions
|
||||
When creating a shared library, bind references to global function
|
||||
symbols to the definition within the shared library, if any.
|
||||
This option is only meaningful on ELF platforms which support shared
|
||||
! libraries.
|
||||
|
||||
@kindex --dynamic-list=@var{dynamic-list-file}
|
||||
@item --dynamic-list=@var{dynamic-list-file}
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/ld/NEWS ./ld/NEWS
|
||||
*** ../binutils-2.20.51.0.7.original/ld/NEWS 2010-04-08 15:03:56.000000000 +0100
|
||||
--- ./ld/NEWS 2010-04-08 15:04:14.000000000 +0100
|
||||
*************** Changes in 2.20:
|
||||
*** 73,83 ****
|
||||
For the switch --enable-runtime-pseudo-reloc it uses for 32-bit
|
||||
runtime pseudo relocation version one, for 64-bit the version two.
|
||||
|
||||
- * ELF: Support environment variable LD_AS_NEEDED for --as-needed.
|
||||
-
|
||||
- * ELF: Support environment variables, LD_SYMBOLIC for -Bsymbolic and
|
||||
- LD_SYMBOLIC_FUNCTIONS for -Bsymbolic-functions.
|
||||
-
|
||||
Changes in 2.19:
|
||||
|
||||
* Linker scripts support a new INSERT command that makes it easier to
|
||||
--- 73,78 ----
|
||||
|
@ -1,115 +0,0 @@
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gas/ChangeLog gas/ChangeLog
|
||||
--- ../binutils-2.20.51.0.2.original/gas/ChangeLog 2009-12-09 11:46:00.000000000 +0000
|
||||
+++ gas/ChangeLog 2009-12-09 11:48:31.000000000 +0000
|
||||
@@ -1,3 +1,10 @@
|
||||
+2009-10-28 Alan Modra <amodra@bigpond.net.au>
|
||||
+
|
||||
+ PR gas/10856
|
||||
+ * expr.c (resolve_expression): Only add "left" value to O_symbol
|
||||
+ expression when the symbol is undefined and different from the
|
||||
+ original symbol. Simplify negative logic.
|
||||
+
|
||||
2009-10-07 Nathan Sidwell <nathan@codesourcery.com>
|
||||
|
||||
* config/tc-arm.c (mapping_state, mapping_state_2): Make dummy
|
||||
Only in ../binutils-2.20.51.0.2.original/gas: .#expr.c
|
||||
Only in ../binutils-2.20.51.0.2.original/gas: #expr.c#
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gas/expr.c gas/expr.c
|
||||
--- ../binutils-2.20.51.0.2.original/gas/expr.c 2009-12-09 11:45:56.000000000 +0000
|
||||
+++ gas/expr.c 2009-12-09 11:48:10.000000000 +0000
|
||||
@@ -1997,6 +1997,7 @@ resolve_expression (expressionS *express
|
||||
/* Help out with CSE. */
|
||||
valueT final_val = expressionP->X_add_number;
|
||||
symbolS *add_symbol = expressionP->X_add_symbol;
|
||||
+ symbolS *orig_add_symbol = add_symbol;
|
||||
symbolS *op_symbol = expressionP->X_op_symbol;
|
||||
operatorT op = expressionP->X_op;
|
||||
valueT left, right;
|
||||
@@ -2078,6 +2079,7 @@ resolve_expression (expressionS *express
|
||||
left = right;
|
||||
seg_left = seg_right;
|
||||
add_symbol = op_symbol;
|
||||
+ orig_add_symbol = expressionP->X_op_symbol;
|
||||
op = O_symbol;
|
||||
break;
|
||||
}
|
||||
@@ -2122,18 +2124,19 @@ resolve_expression (expressionS *express
|
||||
{
|
||||
if (op == O_bit_exclusive_or || op == O_bit_inclusive_or)
|
||||
{
|
||||
- if (seg_right != absolute_section || right != 0)
|
||||
+ if (!(seg_right == absolute_section && right == 0))
|
||||
{
|
||||
seg_left = seg_right;
|
||||
left = right;
|
||||
add_symbol = op_symbol;
|
||||
+ orig_add_symbol = expressionP->X_op_symbol;
|
||||
}
|
||||
op = O_symbol;
|
||||
break;
|
||||
}
|
||||
else if (op == O_left_shift || op == O_right_shift)
|
||||
{
|
||||
- if (seg_left != absolute_section || left != 0)
|
||||
+ if (!(seg_left == absolute_section && left == 0))
|
||||
{
|
||||
op = O_symbol;
|
||||
break;
|
||||
@@ -2150,6 +2153,7 @@ resolve_expression (expressionS *express
|
||||
left = right;
|
||||
add_symbol = op_symbol;
|
||||
op = O_symbol;
|
||||
+ orig_add_symbol = expressionP->X_op_symbol;
|
||||
break;
|
||||
}
|
||||
else if ((op == O_multiply || op == O_divide)
|
||||
@@ -2158,11 +2162,11 @@ resolve_expression (expressionS *express
|
||||
op = O_symbol;
|
||||
break;
|
||||
}
|
||||
- else if (left != right
|
||||
- || ((seg_left != reg_section || seg_right != reg_section)
|
||||
- && (seg_left != undefined_section
|
||||
- || seg_right != undefined_section
|
||||
- || add_symbol != op_symbol)))
|
||||
+ else if (!(left == right
|
||||
+ && ((seg_left == reg_section && seg_right == reg_section)
|
||||
+ || (seg_left == undefined_section
|
||||
+ && seg_right == undefined_section
|
||||
+ && add_symbol == op_symbol))))
|
||||
return 0;
|
||||
else if (op == O_bit_and || op == O_bit_inclusive_or)
|
||||
{
|
||||
@@ -2233,7 +2237,8 @@ resolve_expression (expressionS *express
|
||||
op = O_constant;
|
||||
else if (seg_left == reg_section && final_val == 0)
|
||||
op = O_register;
|
||||
- else if (add_symbol != expressionP->X_add_symbol)
|
||||
+ else if (seg_left == undefined_section
|
||||
+ && add_symbol != orig_add_symbol)
|
||||
final_val += left;
|
||||
expressionP->X_add_symbol = add_symbol;
|
||||
}
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gas/testsuite/ChangeLog gas/testsuite/ChangeLog
|
||||
--- ../binutils-2.20.51.0.2.original/gas/testsuite/ChangeLog 2009-12-09 11:45:56.000000000 +0000
|
||||
+++ gas/testsuite/ChangeLog 2009-12-09 11:50:11.000000000 +0000
|
||||
@@ -1,3 +1,7 @@
|
||||
+2009-10-28 Alan Modra <amodra@bigpond.net.au>
|
||||
+
|
||||
+ * gas/i386/intelpic.d: Correct.
|
||||
+
|
||||
2009-10-08 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR gas/10704
|
||||
diff -rup ../binutils-2.20.51.0.2.original/gas/testsuite/gas/i386/intelpic.d gas/testsuite/gas/i386/intelpic.d
|
||||
--- ../binutils-2.20.51.0.2.original/gas/testsuite/gas/i386/intelpic.d 2009-12-09 11:45:59.000000000 +0000
|
||||
+++ gas/testsuite/gas/i386/intelpic.d 2009-12-09 11:49:17.000000000 +0000
|
||||
@@ -12,6 +12,6 @@ Disassembly of section .text:
|
||||
0+1 <bar>:
|
||||
[ ]*[a-f0-9]+: 8d 83 14 00 00 00 lea 0x14\(%ebx\),%eax
|
||||
[ ]*[a-f0-9]+: 8b 83 00 00 00 00 mov 0x0\(%ebx\),%eax
|
||||
-[ ]*[a-f0-9]+: ff 24 85 1a 00 00 00 jmp \*0x1a\(,%eax,4\)
|
||||
+[ ]*[a-f0-9]+: ff 24 85 0d 00 00 00 jmp \*0xd\(,%eax,4\)
|
||||
[ ]*[a-f0-9]+: 8d 83 14 00 00 00 lea 0x14\(%ebx\),%eax
|
||||
#pass
|
||||
|
@ -1,34 +0,0 @@
|
||||
2009-11-08 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR ld/10911
|
||||
* elflink.c (elf_link_output_extsym): Don't return on
|
||||
STT_GNU_IFUNC symbol when stripping.
|
||||
|
||||
* ld-ifunc/ifunc-4a-x86.d: New.
|
||||
|
||||
--- bfd/elflink.c
|
||||
+++ bfd/elflink.c
|
||||
@@ -8639,9 +8639,11 @@ elf_link_output_extsym (struct elf_link_hash_entry *h, void *data)
|
||||
strip = FALSE;
|
||||
|
||||
/* If we're stripping it, and it's not a dynamic symbol, there's
|
||||
- nothing else to do unless it is a forced local symbol. */
|
||||
+ nothing else to do unless it is a forced local symbol or a
|
||||
+ STT_GNU_IFUNC symbol. */
|
||||
if (strip
|
||||
&& h->dynindx == -1
|
||||
+ && h->type != STT_GNU_IFUNC
|
||||
&& !h->forced_local)
|
||||
return TRUE;
|
||||
|
||||
--- ld/testsuite/ld-ifunc/ifunc-4a-x86.d
|
||||
+++ ld/testsuite/ld-ifunc/ifunc-4a-x86.d
|
||||
@@ -0,0 +1,8 @@
|
||||
+#ld: -s
|
||||
+#readelf: -r --wide
|
||||
+#target: x86_64-*-* i?86-*-*
|
||||
+#source: ifunc-4-x86.s
|
||||
+
|
||||
+#...
|
||||
+[0-9a-f]+[ ]+[0-9a-f]+[ ]+R_[_0-9A-Z]+_IRELATIVE[ ]*[0-9a-f]*
|
||||
+#pass
|
@ -1,10 +1,22 @@
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/bfd/configure ./bfd/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/configure 2009-10-12 11:28:45.000000000 +0100
|
||||
+++ ./bfd/configure 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -10670,10 +10670,34 @@ fi
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/configure ./bfd/configure
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/configure 2010-04-08 14:53:48.000000000 +0100
|
||||
--- ./bfd/configure 2010-04-08 14:56:50.000000000 +0100
|
||||
*************** fi
|
||||
*** 10762,10771 ****
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
--- 10762,10795 ----
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
@ -29,247 +41,262 @@ diff -rup ../binutils-2.20.51.0.2.orig/bfd/configure ./bfd/configure
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in ./bfd: configure.orig
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/binutils/configure ./binutils/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/binutils/configure 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ./binutils/configure 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -10461,10 +10461,34 @@ fi
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in ./binutils: configure.orig
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/gas/configure ./gas/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/gas/configure 2009-10-12 11:28:45.000000000 +0100
|
||||
+++ ./gas/configure 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -10418,10 +10418,34 @@ fi
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in ./gas: configure.orig
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/gprof/configure ./gprof/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/gprof/configure 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ./gprof/configure 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -10356,10 +10356,34 @@ fi
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in ./gprof: configure.orig
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/ld/configure ./ld/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/ld/configure 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ./ld/configure 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -10806,10 +10806,34 @@ fi
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in ./ld: configure.orig
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/libtool.m4 ./libtool.m4
|
||||
--- ../binutils-2.20.51.0.2.orig/libtool.m4 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ./libtool.m4 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -2475,10 +2475,30 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if AC_TRY_EVAL(ac_compile); then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/opcodes/configure ./opcodes/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/opcodes/configure 2009-10-12 11:28:44.000000000 +0100
|
||||
+++ ./opcodes/configure 2009-10-12 11:31:43.000000000 +0100
|
||||
@@ -10406,10 +10406,34 @@ fi
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
|
||||
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in ./opcodes: configure.orig
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/binutils/configure ./binutils/configure
|
||||
*** ../binutils-2.20.51.0.7.original/binutils/configure 2010-04-08 14:53:45.000000000 +0100
|
||||
--- ./binutils/configure 2010-04-08 14:56:21.000000000 +0100
|
||||
*************** fi
|
||||
*** 10560,10569 ****
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
--- 10560,10593 ----
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/gas/configure ./gas/configure
|
||||
*** ../binutils-2.20.51.0.7.original/gas/configure 2010-04-08 14:53:47.000000000 +0100
|
||||
--- ./gas/configure 2010-04-08 14:57:24.000000000 +0100
|
||||
*************** fi
|
||||
*** 10547,10556 ****
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
--- 10547,10580 ----
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/gprof/configure ./gprof/configure
|
||||
*** ../binutils-2.20.51.0.7.original/gprof/configure 2010-04-08 14:53:45.000000000 +0100
|
||||
--- ./gprof/configure 2010-04-08 14:57:50.000000000 +0100
|
||||
*************** fi
|
||||
*** 10485,10494 ****
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
--- 10485,10518 ----
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/ld/configure ./ld/configure
|
||||
*** ../binutils-2.20.51.0.7.original/ld/configure 2010-04-08 14:53:44.000000000 +0100
|
||||
--- ./ld/configure 2010-04-08 14:58:21.000000000 +0100
|
||||
*************** fi
|
||||
*** 10966,10975 ****
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
--- 10966,10999 ----
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
Only in .: .#libtool.m4
|
||||
Only in .: #libtool.m4#
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/opcodes/configure ./opcodes/configure
|
||||
*** ../binutils-2.20.51.0.7.original/opcodes/configure 2010-04-08 14:53:45.000000000 +0100
|
||||
--- ./opcodes/configure 2010-04-08 14:59:10.000000000 +0100
|
||||
*************** fi
|
||||
*** 10496,10505 ****
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
--- 10496,10529 ----
|
||||
# before this can be enabled.
|
||||
hardcode_into_libs=yes
|
||||
|
||||
+ # find out which ABI we are using
|
||||
+ libsuff=
|
||||
+ case "$host_cpu" in
|
||||
+ x86_64*|s390*|powerpc*|ppc*|sparc*)
|
||||
+ echo 'int i;' > conftest.$ac_ext
|
||||
+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||
+ (eval $ac_compile) 2>&5
|
||||
+ ac_status=$?
|
||||
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||
+ (exit $ac_status); }; then
|
||||
+ case `/usr/bin/file conftest.$ac_objext` in
|
||||
+ *64-bit*)
|
||||
+ libsuff=64
|
||||
+ if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
|
||||
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
|
||||
+ fi
|
||||
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ fi
|
||||
+ rm -rf conftest*
|
||||
+ ;;
|
||||
+ esac
|
||||
+
|
||||
# Append ld.so.conf contents to the search path
|
||||
if test -f /etc/ld.so.conf; then
|
||||
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
|
||||
! sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
|
||||
fi
|
||||
|
||||
# We used to test for /lib/ld.so.1 and disable shared libraries on
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,307 +0,0 @@
|
||||
diff -rup ../binutils-2.20.51.0.2.original/bfd/ChangeLog ./bfd/ChangeLog
|
||||
--- ../binutils-2.20.51.0.2.original/bfd/ChangeLog 2009-12-17 16:08:07.000000000 +0000
|
||||
+++ ./bfd/ChangeLog 2009-12-17 17:20:30.000000000 +0000
|
||||
@@ -1,3 +1,25 @@
|
||||
+2009-12-17 Alan Modra <amodra@bigpond.net.au>
|
||||
+
|
||||
+ PR ld/11088
|
||||
+ * elf64-ppc.c (ppc64_elf_gc_sweep_hook): Don't abort if symbol
|
||||
+ hiding has nulled out plt.plist.
|
||||
+
|
||||
+ PR ld/11088
|
||||
+ * elf32-ppc.c (update_plt_info): Clear sec here when addend is
|
||||
+ less than 32768..
|
||||
+ (ppc_elf_check_relocs): ..rather than doing so here. Ignore new
|
||||
+ relax relocs.
|
||||
+ (ppc_elf_gc_sweep_hook): Don't segfault when symbol hiding has
|
||||
+ removed plt_entry records.
|
||||
+ (ppc_elf_tls_setup): Handle PIE calls to __tls_get_addr correctly.
|
||||
+ (ppc_elf_tls_optimize): Likewise. Also dec __tls_get_addr refcount
|
||||
+ when optimizing code using new tlsgd and tlsld marker relocs.
|
||||
+ (ppc_elf_relax_section): Differentiate relaxed PLTREL24 relocs
|
||||
+ from ADDR24 relocs using plt or glink. Don't clear the addend
|
||||
+ for R_PPC_RELAX_PLTREL24.
|
||||
+ (ppc_elf_relocate_section): Correctly handle addends on relaxed
|
||||
+ PLTREL24 relocs.
|
||||
+
|
||||
2009-10-09 Tristan Gingold <gingold@adacore.com>
|
||||
|
||||
* mach-o.c (bfd_mach_o_section_get_entry_size): Moved.
|
||||
diff -rup ../binutils-2.20.51.0.2.original/bfd/elf32-ppc.c ./bfd/elf32-ppc.c
|
||||
--- ../binutils-2.20.51.0.2.original/bfd/elf32-ppc.c 2009-12-17 16:08:07.000000000 +0000
|
||||
+++ ./bfd/elf32-ppc.c 2009-12-18 13:54:26.000000000 +0000
|
||||
@@ -3323,6 +3323,8 @@ update_plt_info (bfd *abfd, struct plt_e
|
||||
{
|
||||
struct plt_entry *ent;
|
||||
|
||||
+ if (addend < 32768)
|
||||
+ sec = NULL;
|
||||
for (ent = *plist; ent != NULL; ent = ent->next)
|
||||
if (ent->sec == sec && ent->addend == addend)
|
||||
break;
|
||||
@@ -3508,8 +3510,7 @@ ppc_elf_check_relocs (bfd *abfd,
|
||||
if (info->shared)
|
||||
addend = rel->r_addend;
|
||||
}
|
||||
- if (!update_plt_info (abfd, ifunc,
|
||||
- addend < 32768 ? NULL : got2, addend))
|
||||
+ if (!update_plt_info (abfd, ifunc, got2, addend))
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@@ -3748,8 +3749,7 @@ ppc_elf_check_relocs (bfd *abfd,
|
||||
addend = rel->r_addend;
|
||||
}
|
||||
h->needs_plt = 1;
|
||||
- if (!update_plt_info (abfd, &h->plt.plist,
|
||||
- addend < 32768 ? NULL : got2, addend))
|
||||
+ if (!update_plt_info (abfd, &h->plt.plist, got2, addend))
|
||||
return FALSE;
|
||||
}
|
||||
break;
|
||||
@@ -3780,10 +3780,9 @@ ppc_elf_check_relocs (bfd *abfd,
|
||||
case R_PPC_EMB_MRKREF:
|
||||
case R_PPC_NONE:
|
||||
case R_PPC_max:
|
||||
- case R_PPC_RELAX32:
|
||||
- case R_PPC_RELAX32PC:
|
||||
- case R_PPC_RELAX32_PLT:
|
||||
- case R_PPC_RELAX32PC_PLT:
|
||||
+ case R_PPC_RELAX:
|
||||
+ case R_PPC_RELAX_PLT:
|
||||
+ case R_PPC_RELAX_PLTREL24:
|
||||
break;
|
||||
|
||||
/* These should only appear in dynamic objects. */
|
||||
@@ -4486,7 +4485,7 @@ ppc_elf_gc_sweep_hook (bfd *abfd,
|
||||
struct plt_entry *ent;
|
||||
|
||||
ent = find_plt_ent (&h->plt.plist, NULL, 0);
|
||||
- if (ent->plt.refcount > 0)
|
||||
+ if (ent != NULL && ent->plt.refcount > 0)
|
||||
ent->plt.refcount -= 1;
|
||||
}
|
||||
}
|
||||
@@ -4534,7 +4533,7 @@ ppc_elf_gc_sweep_hook (bfd *abfd,
|
||||
if (r_type == R_PPC_PLTREL24 && info->shared)
|
||||
addend = rel->r_addend;
|
||||
ent = find_plt_ent (&h->plt.plist, got2, addend);
|
||||
- if (ent->plt.refcount > 0)
|
||||
+ if (ent != NULL && ent->plt.refcount > 0)
|
||||
ent->plt.refcount -= 1;
|
||||
}
|
||||
break;
|
||||
@@ -4582,9 +4581,11 @@ ppc_elf_tls_setup (bfd *obfd,
|
||||
&& tga->root.type == bfd_link_hash_undefweak)))
|
||||
{
|
||||
struct plt_entry *ent;
|
||||
- ent = find_plt_ent (&tga->plt.plist, NULL, 0);
|
||||
- if (ent != NULL
|
||||
- && ent->plt.refcount > 0)
|
||||
+
|
||||
+ for (ent = tga->plt.plist; ent != NULL; ent = ent->next)
|
||||
+ if (ent->plt.refcount > 0)
|
||||
+ break;
|
||||
+ if (ent != NULL)
|
||||
{
|
||||
tga->root.type = bfd_link_hash_indirect;
|
||||
tga->root.u.i.link = &opt->root;
|
||||
@@ -4669,6 +4670,7 @@ ppc_elf_tls_optimize (bfd *obfd ATTRIBUT
|
||||
{
|
||||
Elf_Internal_Sym *locsyms = NULL;
|
||||
Elf_Internal_Shdr *symtab_hdr = &elf_symtab_hdr (ibfd);
|
||||
+ asection *got2 = bfd_get_section_by_name (ibfd, ".got2");
|
||||
|
||||
for (sec = ibfd->sections; sec != NULL; sec = sec->next)
|
||||
if (sec->has_tls_reloc && !bfd_is_abs_section (sec->output_section))
|
||||
@@ -4762,6 +4764,13 @@ ppc_elf_tls_optimize (bfd *obfd ATTRIBUT
|
||||
else
|
||||
continue;
|
||||
|
||||
+ case R_PPC_TLSGD:
|
||||
+ case R_PPC_TLSLD:
|
||||
+ expecting_tls_get_addr = 2;
|
||||
+ tls_set = 0;
|
||||
+ tls_clear = 0;
|
||||
+ break;
|
||||
+
|
||||
default:
|
||||
continue;
|
||||
}
|
||||
@@ -4769,7 +4778,8 @@ ppc_elf_tls_optimize (bfd *obfd ATTRIBUT
|
||||
if (pass == 0)
|
||||
{
|
||||
if (!expecting_tls_get_addr
|
||||
- || !sec->has_tls_get_addr_call)
|
||||
+ || (expecting_tls_get_addr == 1
|
||||
+ && !sec->has_tls_get_addr_call))
|
||||
continue;
|
||||
|
||||
if (rel + 1 < relend
|
||||
@@ -4785,6 +4795,23 @@ ppc_elf_tls_optimize (bfd *obfd ATTRIBUT
|
||||
break;
|
||||
}
|
||||
|
||||
+ if (expecting_tls_get_addr)
|
||||
+ {
|
||||
+ struct plt_entry *ent;
|
||||
+ bfd_vma addend = 0;
|
||||
+
|
||||
+ if (info->shared
|
||||
+ && ELF32_R_TYPE (rel[1].r_info) == R_PPC_PLTREL24)
|
||||
+ addend = rel[1].r_addend;
|
||||
+ ent = find_plt_ent (&htab->tls_get_addr->plt.plist,
|
||||
+ got2, addend);
|
||||
+ if (ent != NULL && ent->plt.refcount > 0)
|
||||
+ ent->plt.refcount -= 1;
|
||||
+
|
||||
+ if (expecting_tls_get_addr == 2)
|
||||
+ continue;
|
||||
+ }
|
||||
+
|
||||
if (h != NULL)
|
||||
{
|
||||
tls_mask = &ppc_elf_hash_entry (h)->tls_mask;
|
||||
@@ -4829,16 +4856,6 @@ ppc_elf_tls_optimize (bfd *obfd ATTRIBUT
|
||||
*got_count -= 1;
|
||||
}
|
||||
|
||||
- if (expecting_tls_get_addr)
|
||||
- {
|
||||
- struct plt_entry *ent;
|
||||
-
|
||||
- ent = find_plt_ent (&htab->tls_get_addr->plt.plist,
|
||||
- NULL, 0);
|
||||
- if (ent != NULL && ent->plt.refcount > 0)
|
||||
- ent->plt.refcount -= 1;
|
||||
- }
|
||||
-
|
||||
*tls_mask |= tls_set;
|
||||
*tls_mask &= ~tls_clear;
|
||||
}
|
||||
@@ -6239,28 +6256,29 @@ ppc_elf_relax_section (bfd *abfd,
|
||||
{
|
||||
size = 4 * ARRAY_SIZE (shared_stub_entry);
|
||||
insn_offset = 12;
|
||||
- stub_rtype = R_PPC_RELAX32PC;
|
||||
}
|
||||
else
|
||||
{
|
||||
size = 4 * ARRAY_SIZE (stub_entry);
|
||||
insn_offset = 0;
|
||||
- stub_rtype = R_PPC_RELAX32;
|
||||
}
|
||||
|
||||
- if (R_PPC_RELAX32_PLT - R_PPC_RELAX32
|
||||
- != R_PPC_RELAX32PC_PLT - R_PPC_RELAX32PC)
|
||||
- abort ();
|
||||
+ stub_rtype = R_PPC_RELAX;
|
||||
if (tsec == htab->plt
|
||||
|| tsec == htab->glink)
|
||||
- stub_rtype += R_PPC_RELAX32_PLT - R_PPC_RELAX32;
|
||||
+ {
|
||||
+ stub_rtype = R_PPC_RELAX_PLT;
|
||||
+ if (r_type == R_PPC_PLTREL24)
|
||||
+ stub_rtype = R_PPC_RELAX_PLTREL24;
|
||||
+ }
|
||||
|
||||
/* Hijack the old relocation. Since we need two
|
||||
relocations for this use a "composite" reloc. */
|
||||
irel->r_info = ELF32_R_INFO (ELF32_R_SYM (irel->r_info),
|
||||
stub_rtype);
|
||||
irel->r_offset = trampoff + insn_offset;
|
||||
- if (r_type == R_PPC_PLTREL24)
|
||||
+ if (r_type == R_PPC_PLTREL24
|
||||
+ && stub_rtype != R_PPC_RELAX_PLTREL24)
|
||||
irel->r_addend = 0;
|
||||
|
||||
/* Record the fixup so we don't do it again this section. */
|
||||
@@ -6430,7 +6448,7 @@ ppc_elf_relax_section (bfd *abfd,
|
||||
{
|
||||
/* Convert the internal relax relocs to external form. */
|
||||
for (irel = internal_relocs; irel < irelend; irel++)
|
||||
- if (ELF32_R_TYPE (irel->r_info) == R_PPC_RELAX32)
|
||||
+ if (ELF32_R_TYPE (irel->r_info) == R_PPC_RELAX)
|
||||
{
|
||||
unsigned long r_symndx = ELF32_R_SYM (irel->r_info);
|
||||
|
||||
@@ -7655,12 +7673,20 @@ ppc_elf_relocate_section (bfd *output_bf
|
||||
}
|
||||
break;
|
||||
|
||||
- case R_PPC_RELAX32PC_PLT:
|
||||
- case R_PPC_RELAX32_PLT:
|
||||
+ case R_PPC_RELAX_PLT:
|
||||
+ case R_PPC_RELAX_PLTREL24:
|
||||
if (h != NULL)
|
||||
{
|
||||
- struct plt_entry *ent = find_plt_ent (&h->plt.plist, got2,
|
||||
- info->shared ? addend : 0);
|
||||
+ struct plt_entry *ent;
|
||||
+ bfd_vma got2_addend = 0;
|
||||
+
|
||||
+ if (r_type == R_PPC_RELAX_PLTREL24)
|
||||
+ {
|
||||
+ if (info->shared)
|
||||
+ got2_addend = addend;
|
||||
+ addend = 0;
|
||||
+ }
|
||||
+ ent = find_plt_ent (&h->plt.plist, got2, got2_addend);
|
||||
if (htab->plt_type == PLT_NEW)
|
||||
relocation = (htab->glink->output_section->vma
|
||||
+ htab->glink->output_offset
|
||||
@@ -7670,18 +7696,13 @@ ppc_elf_relocate_section (bfd *output_bf
|
||||
+ htab->plt->output_offset
|
||||
+ ent->plt.offset);
|
||||
}
|
||||
- if (r_type == R_PPC_RELAX32_PLT)
|
||||
- goto relax32;
|
||||
/* Fall thru */
|
||||
|
||||
- case R_PPC_RELAX32PC:
|
||||
- relocation -= (input_section->output_section->vma
|
||||
- + input_section->output_offset
|
||||
- + rel->r_offset - 4);
|
||||
- /* Fall thru */
|
||||
-
|
||||
- case R_PPC_RELAX32:
|
||||
- relax32:
|
||||
+ case R_PPC_RELAX:
|
||||
+ if (info->shared)
|
||||
+ relocation -= (input_section->output_section->vma
|
||||
+ + input_section->output_offset
|
||||
+ + rel->r_offset - 4);
|
||||
{
|
||||
unsigned long t0;
|
||||
unsigned long t1;
|
||||
diff -rup ../binutils-2.20.51.0.2.original/bfd/elf64-ppc.c ./bfd/elf64-ppc.c
|
||||
--- ../binutils-2.20.51.0.2.original/bfd/elf64-ppc.c 2009-12-17 16:08:07.000000000 +0000
|
||||
+++ ./bfd/elf64-ppc.c 2009-12-17 17:20:30.000000000 +0000
|
||||
@@ -5866,9 +5866,7 @@ ppc64_elf_gc_sweep_hook (bfd *abfd, stru
|
||||
for (ent = h->plt.plist; ent != NULL; ent = ent->next)
|
||||
if (ent->addend == rel->r_addend)
|
||||
break;
|
||||
- if (ent == NULL)
|
||||
- abort ();
|
||||
- if (ent->plt.refcount > 0)
|
||||
+ if (ent != NULL && ent->plt.refcount > 0)
|
||||
ent->plt.refcount -= 1;
|
||||
}
|
||||
break;
|
||||
diff -rup ../binutils-2.20.51.0.2.original/include/elf/ppc.h ./include/elf/ppc.h
|
||||
--- ../binutils-2.20.51.0.2.original/include/elf/ppc.h 2009-12-17 16:07:45.000000000 +0000
|
||||
+++ ./include/elf/ppc.h 2009-12-17 17:20:30.000000000 +0000
|
||||
@@ -73,10 +73,9 @@ START_RELOC_NUMBERS (elf_ppc_reloc_type)
|
||||
|
||||
#ifndef RELOC_MACROS_GEN_FUNC
|
||||
/* Fake relocations for branch stubs, only used internally by ld. */
|
||||
- RELOC_NUMBER (R_PPC_RELAX32, 48)
|
||||
- RELOC_NUMBER (R_PPC_RELAX32PC, 49)
|
||||
- RELOC_NUMBER (R_PPC_RELAX32_PLT, 50)
|
||||
- RELOC_NUMBER (R_PPC_RELAX32PC_PLT, 51)
|
||||
+ RELOC_NUMBER (R_PPC_RELAX, 48)
|
||||
+ RELOC_NUMBER (R_PPC_RELAX_PLT, 49)
|
||||
+ RELOC_NUMBER (R_PPC_RELAX_PLTREL24, 50)
|
||||
#endif
|
||||
|
||||
/* Relocs added to support TLS. */
|
@ -1,16 +1,25 @@
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/elf64-ppc.c 2009-10-12 11:28:45.000000000 +0100
|
||||
+++ bfd/elf64-ppc.c 2009-10-12 11:34:17.000000000 +0100
|
||||
@@ -11992,7 +11992,12 @@ ppc64_elf_relocate_section (bfd *output_
|
||||
else if (!SYMBOL_REFERENCES_LOCAL (info, &h->elf)
|
||||
&& !is_opd
|
||||
&& r_type != R_PPC64_TOC)
|
||||
- outrel.r_info = ELF64_R_INFO (h->elf.dynindx, r_type);
|
||||
+ {
|
||||
+ outrel.r_info = ELF64_R_INFO (h->elf.dynindx, r_type);
|
||||
+ if (h->elf.dynindx == -1
|
||||
+ && h->elf.root.type == bfd_link_hash_undefweak)
|
||||
+ memset (&outrel, 0, sizeof outrel);
|
||||
+ }
|
||||
else
|
||||
{
|
||||
/* This symbol is local, or marked to become local,
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/elf64-ppc.c ./bfd/elf64-ppc.c
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/elf64-ppc.c 2010-04-08 15:01:45.000000000 +0100
|
||||
--- ./bfd/elf64-ppc.c 2010-04-08 15:02:05.000000000 +0100
|
||||
*************** ppc64_elf_relocate_section (bfd *output_
|
||||
*** 12558,12564 ****
|
||||
else if (!SYMBOL_REFERENCES_LOCAL (info, &h->elf)
|
||||
&& !is_opd
|
||||
&& r_type != R_PPC64_TOC)
|
||||
! outrel.r_info = ELF64_R_INFO (h->elf.dynindx, r_type);
|
||||
else
|
||||
{
|
||||
/* This symbol is local, or marked to become local,
|
||||
--- 12558,12569 ----
|
||||
else if (!SYMBOL_REFERENCES_LOCAL (info, &h->elf)
|
||||
&& !is_opd
|
||||
&& r_type != R_PPC64_TOC)
|
||||
! {
|
||||
! outrel.r_info = ELF64_R_INFO (h->elf.dynindx, r_type);
|
||||
! if (h->elf.dynindx == -1
|
||||
! && h->elf.root.type == bfd_link_hash_undefweak)
|
||||
! memset (&outrel, 0, sizeof outrel);
|
||||
! }
|
||||
else
|
||||
{
|
||||
/* This symbol is local, or marked to become local,
|
||||
|
@ -1,38 +1,60 @@
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/bfd/configure bfd/configure
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/configure 2009-10-12 11:45:05.000000000 +0100
|
||||
+++ bfd/configure 2009-10-12 11:45:13.000000000 +0100
|
||||
@@ -12694,11 +12694,13 @@ if test "x${ac_cv_sizeof_long}" = "x8";
|
||||
BFD_HOST_64BIT_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
|
||||
-elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
+fi
|
||||
+if test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
BFD_HOST_64BIT_LONG_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
|
||||
- if test "x${ac_cv_sizeof_void_p}" = "x8"; then
|
||||
+ if test "x${ac_cv_sizeof_void_p}" = "x8" \
|
||||
+ -a "x${ac_cv_sizeof_long}" != "x8"; then
|
||||
BFD_HOSTPTR_T="unsigned long long"
|
||||
fi
|
||||
fi
|
||||
diff -rup ../binutils-2.20.51.0.2.orig/bfd/configure.in bfd/configure.in
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/configure.in 2009-10-12 11:45:05.000000000 +0100
|
||||
+++ bfd/configure.in 2009-10-12 11:45:13.000000000 +0100
|
||||
@@ -172,11 +172,13 @@ if test "x${ac_cv_sizeof_long}" = "x8";
|
||||
BFD_HOST_64BIT_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
|
||||
-elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
+fi
|
||||
+if test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
BFD_HOST_64BIT_LONG_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
|
||||
- if test "x${ac_cv_sizeof_void_p}" = "x8"; then
|
||||
+ if test "x${ac_cv_sizeof_void_p}" = "x8" \
|
||||
+ -a "x${ac_cv_sizeof_long}" != "x8"; then
|
||||
BFD_HOSTPTR_T="unsigned long long"
|
||||
fi
|
||||
fi
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/configure ./bfd/configure
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/configure 2010-04-08 15:23:58.000000000 +0100
|
||||
--- ./bfd/configure 2010-04-08 15:24:06.000000000 +0100
|
||||
*************** if test "x${ac_cv_sizeof_long}" = "x8";
|
||||
*** 12819,12829 ****
|
||||
BFD_HOST_64BIT_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
|
||||
! elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
BFD_HOST_64BIT_LONG_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
|
||||
! if test "x${ac_cv_sizeof_void_p}" = "x8"; then
|
||||
BFD_HOSTPTR_T="unsigned long long"
|
||||
fi
|
||||
fi
|
||||
--- 12819,12831 ----
|
||||
BFD_HOST_64BIT_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
|
||||
! fi
|
||||
! if test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
BFD_HOST_64BIT_LONG_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
|
||||
! if test "x${ac_cv_sizeof_void_p}" = "x8" \
|
||||
! -a "x${ac_cv_sizeof_long}" != "x8"; then
|
||||
BFD_HOSTPTR_T="unsigned long long"
|
||||
fi
|
||||
fi
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/configure.in ./bfd/configure.in
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/configure.in 2010-04-08 15:23:58.000000000 +0100
|
||||
--- ./bfd/configure.in 2010-04-08 15:24:06.000000000 +0100
|
||||
*************** if test "x${ac_cv_sizeof_long}" = "x8";
|
||||
*** 153,163 ****
|
||||
BFD_HOST_64BIT_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
|
||||
! elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
BFD_HOST_64BIT_LONG_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
|
||||
! if test "x${ac_cv_sizeof_void_p}" = "x8"; then
|
||||
BFD_HOSTPTR_T="unsigned long long"
|
||||
fi
|
||||
fi
|
||||
--- 153,165 ----
|
||||
BFD_HOST_64BIT_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
|
||||
! fi
|
||||
! if test "x${ac_cv_sizeof_long_long}" = "x8"; then
|
||||
BFD_HOST_64BIT_LONG_LONG=1
|
||||
test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
|
||||
test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
|
||||
! if test "x${ac_cv_sizeof_void_p}" = "x8" \
|
||||
! -a "x${ac_cv_sizeof_long}" != "x8"; then
|
||||
BFD_HOSTPTR_T="unsigned long long"
|
||||
fi
|
||||
fi
|
||||
|
@ -1,36 +1,61 @@
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/Makefile.am 2009-10-12 11:28:45.000000000 +0100
|
||||
+++ bfd/Makefile.am 2009-10-12 11:42:24.000000000 +0100
|
||||
@@ -951,12 +951,12 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/
|
||||
report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
|
||||
if test "x$(RELEASE)" = x ; then \
|
||||
bfd_version_date=`sed -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
|
||||
- bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
|
||||
- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
|
||||
+ bfd_version_string="\"$(VERSION)-%{release} $${bfd_version_date}\"" ;\
|
||||
+ bfd_soversion="$(VERSION)-%{release}" ;\
|
||||
fi ;\
|
||||
sed -e "s,@bfd_version@,$$bfd_version," \
|
||||
-e "s,@bfd_version_string@,$$bfd_version_string," \
|
||||
- -e "s,@bfd_version_package@,$$bfd_version_package," \
|
||||
+ -e "s,@bfd_version_package@,\"version \"," \
|
||||
-e "s,@report_bugs_to@,$$report_bugs_to," \
|
||||
< $(srcdir)/version.h > $@; \
|
||||
echo "$${bfd_soversion}" > libtool-soversion
|
||||
--- ../binutils-2.20.51.0.2.orig/bfd/Makefile.in 2009-10-12 11:28:45.000000000 +0100
|
||||
+++ bfd/Makefile.in 2009-10-12 11:42:24.000000000 +0100
|
||||
@@ -1978,12 +1978,12 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/
|
||||
report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
|
||||
if test "x$(RELEASE)" = x ; then \
|
||||
bfd_version_date=`sed -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
|
||||
- bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
|
||||
- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
|
||||
+ bfd_version_string="\"$(VERSION)-%{release} $${bfd_version_date}\"" ;\
|
||||
+ bfd_soversion="$(VERSION)-%{release}" ;\
|
||||
fi ;\
|
||||
sed -e "s,@bfd_version@,$$bfd_version," \
|
||||
-e "s,@bfd_version_string@,$$bfd_version_string," \
|
||||
- -e "s,@bfd_version_package@,$$bfd_version_package," \
|
||||
+ -e "s,@bfd_version_package@,\"version \"," \
|
||||
-e "s,@report_bugs_to@,$$report_bugs_to," \
|
||||
< $(srcdir)/version.h > $@; \
|
||||
echo "$${bfd_soversion}" > libtool-soversion
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/Makefile.am ./bfd/Makefile.am
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/Makefile.am 2010-04-08 15:07:55.000000000 +0100
|
||||
--- ./bfd/Makefile.am 2010-04-08 15:23:14.000000000 +0100
|
||||
*************** bfdver.h: $(srcdir)/version.h $(srcdir)/
|
||||
*** 953,964 ****
|
||||
report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
|
||||
if test "x$(RELEASE)" = x ; then \
|
||||
bfd_version_date=`sed -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
|
||||
! bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
|
||||
! bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
|
||||
fi ;\
|
||||
sed -e "s,@bfd_version@,$$bfd_version," \
|
||||
-e "s,@bfd_version_string@,$$bfd_version_string," \
|
||||
! -e "s,@bfd_version_package@,$$bfd_version_package," \
|
||||
-e "s,@report_bugs_to@,$$report_bugs_to," \
|
||||
< $(srcdir)/version.h > $@; \
|
||||
echo "$${bfd_soversion}" > libtool-soversion
|
||||
--- 953,964 ----
|
||||
report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
|
||||
if test "x$(RELEASE)" = x ; then \
|
||||
bfd_version_date=`sed -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
|
||||
! bfd_version_string="\"$(VERSION)-%{release} $${bfd_version_date}\"" ;\
|
||||
! bfd_soversion="$(VERSION)-%{release}" ;\
|
||||
fi ;\
|
||||
sed -e "s,@bfd_version@,$$bfd_version," \
|
||||
-e "s,@bfd_version_string@,$$bfd_version_string," \
|
||||
! -e "s,@bfd_version_package@,\"version \"," \
|
||||
-e "s,@report_bugs_to@,$$report_bugs_to," \
|
||||
< $(srcdir)/version.h > $@; \
|
||||
echo "$${bfd_soversion}" > libtool-soversion
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/Makefile.in ./bfd/Makefile.in
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/Makefile.in 2010-04-08 15:07:55.000000000 +0100
|
||||
--- ./bfd/Makefile.in 2010-04-08 15:23:14.000000000 +0100
|
||||
*************** bfdver.h: $(srcdir)/version.h $(srcdir)/
|
||||
*** 1982,1993 ****
|
||||
report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
|
||||
if test "x$(RELEASE)" = x ; then \
|
||||
bfd_version_date=`sed -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
|
||||
! bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
|
||||
! bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
|
||||
fi ;\
|
||||
sed -e "s,@bfd_version@,$$bfd_version," \
|
||||
-e "s,@bfd_version_string@,$$bfd_version_string," \
|
||||
! -e "s,@bfd_version_package@,$$bfd_version_package," \
|
||||
-e "s,@report_bugs_to@,$$report_bugs_to," \
|
||||
< $(srcdir)/version.h > $@; \
|
||||
echo "$${bfd_soversion}" > libtool-soversion
|
||||
--- 1982,1993 ----
|
||||
report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
|
||||
if test "x$(RELEASE)" = x ; then \
|
||||
bfd_version_date=`sed -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
|
||||
! bfd_version_string="\"$(VERSION)-%{release} $${bfd_version_date}\"" ;\
|
||||
! bfd_soversion="$(VERSION)-%{release}" ;\
|
||||
fi ;\
|
||||
sed -e "s,@bfd_version@,$$bfd_version," \
|
||||
-e "s,@bfd_version_string@,$$bfd_version_string," \
|
||||
! -e "s,@bfd_version_package@,\"version \"," \
|
||||
-e "s,@report_bugs_to@,$$report_bugs_to," \
|
||||
< $(srcdir)/version.h > $@; \
|
||||
echo "$${bfd_soversion}" > libtool-soversion
|
||||
|
||||
|
@ -1,92 +0,0 @@
|
||||
diff -rup ../binutils-2.20.51.0.2.original/bfd/elf32-i386.c ./bfd/elf32-i386.c
|
||||
--- ../binutils-2.20.51.0.2.original/bfd/elf32-i386.c 2010-01-13 16:01:28.000000000 +0000
|
||||
+++ ./bfd/elf32-i386.c 2010-02-02 13:07:58.000000000 +0000
|
||||
@@ -653,19 +653,8 @@ struct elf_i386_link_hash_table
|
||||
asection *sdynbss;
|
||||
asection *srelbss;
|
||||
|
||||
- /* The (unloaded but important) .rel.plt.unloaded section on VxWorks. */
|
||||
- asection *srelplt2;
|
||||
-
|
||||
- /* True if the target system is VxWorks. */
|
||||
- int is_vxworks;
|
||||
-
|
||||
- /* Value used to fill the last word of the first plt entry. */
|
||||
- bfd_byte plt0_pad_byte;
|
||||
-
|
||||
- /* The index of the next unused R_386_TLS_DESC slot in .rel.plt. */
|
||||
- bfd_vma next_tls_desc_index;
|
||||
-
|
||||
- union {
|
||||
+ union
|
||||
+ {
|
||||
bfd_signed_vma refcount;
|
||||
bfd_vma offset;
|
||||
} tls_ldm_got;
|
||||
@@ -682,10 +671,22 @@ struct elf_i386_link_hash_table
|
||||
|
||||
/* Used by local STT_GNU_IFUNC symbols. */
|
||||
htab_t loc_hash_table;
|
||||
- void *loc_hash_memory;
|
||||
+ void * loc_hash_memory;
|
||||
|
||||
asection *sdynsharablebss;
|
||||
asection *srelsharablebss;
|
||||
+
|
||||
+ /* The (unloaded but important) .rel.plt.unloaded section on VxWorks. */
|
||||
+ asection *srelplt2;
|
||||
+
|
||||
+ /* True if the target system is VxWorks. */
|
||||
+ int is_vxworks;
|
||||
+
|
||||
+ /* The index of the next unused R_386_TLS_DESC slot in .rel.plt. */
|
||||
+ bfd_vma next_tls_desc_index;
|
||||
+
|
||||
+ /* Value used to fill the last word of the first PLT entry. */
|
||||
+ bfd_byte plt0_pad_byte;
|
||||
};
|
||||
|
||||
/* Get the i386 ELF linker hash table from a link_info structure. */
|
||||
diff -rup ../binutils-2.20.51.0.2.original/bfd/elf64-x86-64.c ./bfd/elf64-x86-64.c
|
||||
--- ../binutils-2.20.51.0.2.original/bfd/elf64-x86-64.c 2010-01-13 16:01:27.000000000 +0000
|
||||
+++ ./bfd/elf64-x86-64.c 2010-02-02 13:15:52.000000000 +0000
|
||||
@@ -470,16 +470,8 @@ struct elf64_x86_64_link_hash_table
|
||||
asection *sdynbss;
|
||||
asection *srelbss;
|
||||
|
||||
- /* The offset into splt of the PLT entry for the TLS descriptor
|
||||
- resolver. Special values are 0, if not necessary (or not found
|
||||
- to be necessary yet), and -1 if needed but not determined
|
||||
- yet. */
|
||||
- bfd_vma tlsdesc_plt;
|
||||
- /* The offset into sgot of the GOT entry used by the PLT entry
|
||||
- above. */
|
||||
- bfd_vma tlsdesc_got;
|
||||
-
|
||||
- union {
|
||||
+ union
|
||||
+ {
|
||||
bfd_signed_vma refcount;
|
||||
bfd_vma offset;
|
||||
} tls_ld_got;
|
||||
@@ -495,10 +487,19 @@ struct elf64_x86_64_link_hash_table
|
||||
|
||||
/* Used by local STT_GNU_IFUNC symbols. */
|
||||
htab_t loc_hash_table;
|
||||
- void *loc_hash_memory;
|
||||
+ void * loc_hash_memory;
|
||||
|
||||
asection *sdynsharablebss;
|
||||
asection *srelsharablebss;
|
||||
+
|
||||
+ /* The offset into splt of the PLT entry for the TLS descriptor
|
||||
+ resolver. Special values are 0, if not necessary (or not found
|
||||
+ to be necessary yet), and -1 if needed but not determined
|
||||
+ yet. */
|
||||
+ bfd_vma tlsdesc_plt;
|
||||
+ /* The offset into sgot of the GOT entry used by the PLT entry
|
||||
+ above. */
|
||||
+ bfd_vma tlsdesc_got;
|
||||
};
|
||||
|
||||
/* Get the x86-64 ELF linker hash table from a link_info structure. */
|
@ -0,0 +1,41 @@
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/ChangeLog ./bfd/ChangeLog
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/ChangeLog 2010-04-08 15:35:35.000000000 +0100
|
||||
--- ./bfd/ChangeLog 2010-04-08 15:38:09.000000000 +0100
|
||||
***************
|
||||
*** 1,3 ****
|
||||
--- 1,12 ----
|
||||
+ 2010-04-07 Nick Clifton <nickc@redhat.com>
|
||||
+
|
||||
+ Import this patch from the mainline:
|
||||
+
|
||||
+ 2010-03-26 H.J. Lu <hongjiu.lu@intel.com>
|
||||
+
|
||||
+ PR ld/11434
|
||||
+ * elf-bfd.h (SYMBOLIC_BIND): Don't bind unique symbols locally.
|
||||
+
|
||||
2010-03-18 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR binutils/11396
|
||||
diff -rcp ../binutils-2.20.51.0.7.original/bfd/elf-bfd.h ./bfd/elf-bfd.h
|
||||
*** ../binutils-2.20.51.0.7.original/bfd/elf-bfd.h 2010-04-08 15:35:35.000000000 +0100
|
||||
--- ./bfd/elf-bfd.h 2010-04-08 15:37:41.000000000 +0100
|
||||
*************** extern asection _bfd_elf_large_com_secti
|
||||
*** 2351,2358 ****
|
||||
while (0)
|
||||
|
||||
/* Will a symbol be bound to the the definition within the shared
|
||||
! library, if any. */
|
||||
#define SYMBOLIC_BIND(INFO, H) \
|
||||
! ((INFO)->symbolic || ((INFO)->dynamic && !(H)->dynamic))
|
||||
|
||||
#endif /* _LIBELF_H_ */
|
||||
--- 2351,2359 ----
|
||||
while (0)
|
||||
|
||||
/* Will a symbol be bound to the the definition within the shared
|
||||
! library, if any. A unique symbol can never be bound locally. */
|
||||
#define SYMBOLIC_BIND(INFO, H) \
|
||||
! (! (H)->unique_global \
|
||||
! && ((INFO)->symbolic || ((INFO)->dynamic && !(H)->dynamic)))
|
||||
|
||||
#endif /* _LIBELF_H_ */
|
1326
binutils-2.20.51.0.7-dwarf4.patch
Normal file
1326
binutils-2.20.51.0.7-dwarf4.patch
Normal file
File diff suppressed because it is too large
Load Diff
@ -16,8 +16,8 @@
|
||||
|
||||
Summary: A GNU collection of binary utilities
|
||||
Name: %{?cross}binutils%{?_with_debug:-debug}
|
||||
Version: 2.20.51.0.2
|
||||
Release: 17%{?dist}
|
||||
Version: 2.20.51.0.7
|
||||
Release: 1%{?dist}
|
||||
License: GPLv3+
|
||||
Group: Development/Tools
|
||||
URL: http://sources.redhat.com/binutils
|
||||
@ -30,15 +30,9 @@ Patch04: binutils-2.20.51.0.2-envvar-revert.patch
|
||||
Patch05: binutils-2.20.51.0.2-version.patch
|
||||
Patch06: binutils-2.20.51.0.2-set-long-long.patch
|
||||
Patch07: binutils-2.20.51.0.2-build-id.patch
|
||||
Patch08: binutils-2.20.51.0.2-add-needed.patch
|
||||
Patch09: binutils-2.20.51.0.2-ifunc-ld-s.patch
|
||||
Patch10: binutils-2.20.51.0.2-lwp.patch
|
||||
Patch11: binutils-2.20.51.0.2-enable-gold.patch
|
||||
Patch12: binutils-2.20.51.0.2-gas-expr.patch
|
||||
Patch13: binutils-2.20.51.0.2-ppc-hidden-plt-relocs.patch
|
||||
Patch14: binutils-2.20.51.0.2-x86-hash-table.patch
|
||||
Patch15: binutils-2.20.51.0.2-copy-osabi.patch
|
||||
Patch16: binutils-2.20.51.0.2-do-not-set-ifunc.patch
|
||||
Patch08: binutils-2.20.51.0.2-copy-osabi.patch
|
||||
Patch09: binutils-2.20.51.0.7-do-not-bind-unique-symbols-locally.patch
|
||||
Patch10: binutils-2.20.51.0.7-dwarf4.patch
|
||||
|
||||
%define gold_arches %ix86 x86_64
|
||||
|
||||
@ -138,15 +132,9 @@ libelf instead of BFD.
|
||||
%patch05 -p0 -b .version~
|
||||
%patch06 -p0 -b .set-long-long~
|
||||
%patch07 -p0 -b .build-id~
|
||||
%patch08 -p0 -b .add-needed~
|
||||
%patch09 -p0 -b .ifunc-ld-s~
|
||||
%patch10 -p0 -b .lwp~
|
||||
%patch11 -p0 -b .enable-gold~
|
||||
%patch12 -p0 -b .gas-expr~
|
||||
%patch13 -p0 -b .hidden-plt~
|
||||
%patch14 -p0 -b .hash-table~
|
||||
%patch15 -p0 -b .copy-osabi~
|
||||
%patch16 -p0 -b .no-ifunc~
|
||||
%patch08 -p0 -b .copy-osabi~
|
||||
%patch09 -p0 -b .do-not-bind-unique~
|
||||
%patch10 -p0 -b .dwarf4~
|
||||
|
||||
# We cannot run autotools as there is an exact requirement of autoconf-2.59.
|
||||
|
||||
@ -449,6 +437,20 @@ exit 0
|
||||
%endif # %{isnative}
|
||||
|
||||
%changelog
|
||||
* Thu Apr 8 2010 Nick Clifton <nickc@redhat.com> - 2.20.51.0.7-1
|
||||
- Rebase on 2.20.51.0.7 tarball.
|
||||
- Delete redundant patches:
|
||||
binutils-2.20.51.0.2-add-needed.patch,
|
||||
binutils-2.20.51.0.2-do-not-set-ifunc.patch,
|
||||
binutils-2.20.51.0.2-enable-gold.patch,
|
||||
binutils-2.20.51.0.2-gas-expr.patch,
|
||||
binutils-2.20.51.0.2-ifunc-ld-s.patch,
|
||||
binutils-2.20.51.0.2-lwp.patch,
|
||||
binutils-2.20.51.0.2-ppc-hidden-plt-relocs.patch,
|
||||
binutils-2.20.51.0.2-x86-hash-table.patch,
|
||||
- Do not allow unique symbols to be bound locally. (PR ld/11434)
|
||||
- Add support for DWARF4 debug information.
|
||||
|
||||
* Thu Mar 4 2010 Nick Clifton <nickc@redhat.com> - 2.20.51.0.2-17
|
||||
- Do not set ELFOSABI_LINUX on binaries which just link to IFUNC using DSOs. (BZ 568941)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user