2007-04-05  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/4304
	* elflink.c (bfd_elf_final_link): Call einfo callback in
	bfd_link_info instead of _bfd_error_handler for DT_TEXTREL
	warning.

ld/testsuite/

2007-04-05  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/4304
	* ld-i386/i386.exp: Run "warn1".

	* ld-i386/warn1.d: New file.
	* ld-i386/warn1.s: Likewise.
This commit is contained in:
H.J. Lu 2007-04-05 16:16:28 +00:00
parent ea9cd3c85b
commit 9267588cdc
6 changed files with 27 additions and 2 deletions

View File

@ -1,3 +1,10 @@
2007-04-05 H.J. Lu <hongjiu.lu@intel.com>
PR ld/4304
* elflink.c (bfd_elf_final_link): Call einfo callback in
bfd_link_info instead of _bfd_error_handler for DT_TEXTREL
warning.
2007-04-05 Alan Modra <amodra@bigpond.net.au>
* elf32-spu.c (spu_elf_output_symbol_hook): New function.

View File

@ -9944,8 +9944,8 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
if (dyn.d_tag == DT_TEXTREL)
{
_bfd_error_handler
(_("warning: creating a DT_TEXTREL in a shared object."));
info->callbacks->einfo
(_("%P: warning: creating a DT_TEXTREL in a shared object.\n"));
break;
}
}

View File

@ -1,3 +1,11 @@
2007-04-05 H.J. Lu <hongjiu.lu@intel.com>
PR ld/4304
* ld-i386/i386.exp: Run "warn1".
* ld-i386/warn1.d: New file.
* ld-i386/warn1.s: Likewise.
2007-04-05 H.J. Lu <hongjiu.lu@intel.com>
* ld-i386/combreloc.d: Remove #target: i?86-*-*.

View File

@ -115,3 +115,4 @@ run_dump_test "pcrel8"
run_dump_test "pcrel16"
run_dump_test "pcrel16abs"
run_dump_test "alloc"
run_dump_test "warn1"

View File

@ -0,0 +1,4 @@
#name: --warn-shared-textrel --fatal-warnings
#as: --32
#ld: -shared -melf_i386 --warn-shared-textrel --fatal-warnings
#error: .*warning: creating a DT_TEXTREL in a shared object.

View File

@ -0,0 +1,5 @@
.text
.globl foo
.type foo, @function
foo:
movl bar, %eax