This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Allow R_68K_TLS_LE{8,16,32} for PIE


This is the same bug that was fixed some time ago for arm, alpha and sh,
triggered by the gcc tls tests.  Tested on m68k-linux and committed as
obvious.

Andreas.

2012-03-31  Andreas Schwab  <schwab@linux-m68k.org>

	* elf32-m68k.c (elf_m68k_relocate_section): Allow
	R_68K_TLS_LE{8,16,32} for PIE.

diff --git a/bfd/elf32-m68k.c b/bfd/elf32-m68k.c
index b7b10c3..d398fba 100644
--- a/bfd/elf32-m68k.c
+++ b/bfd/elf32-m68k.c
@@ -3948,7 +3948,7 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
 	case R_68K_TLS_LE32:
 	case R_68K_TLS_LE16:
 	case R_68K_TLS_LE8:
-	  if (info->shared)
+	  if (info->shared && !info->pie)
 	    {
 	      (*_bfd_error_handler)
 		(_("%B(%A+0x%lx): R_68K_TLS_LE32 relocation not permitted "
-- 
1.7.9.5

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]