]> git.pld-linux.org Git - packages/binutils.git/commitdiff
- PR414 fixed.
authorPaweł Sikora <pluto@pld-linux.org>
Fri, 1 Oct 2004 04:55:46 +0000 (04:55 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- release 3.

Changed files:
    binutils-pr414.patch -> 1.1
    binutils.spec -> 1.183

binutils-pr414.patch [new file with mode: 0644]
binutils.spec

diff --git a/binutils-pr414.patch b/binutils-pr414.patch
new file mode 100644 (file)
index 0000000..436fd58
--- /dev/null
@@ -0,0 +1,105 @@
+2004-09-29  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR 414
+       * elflink.c (_bfd_elf_merge_symbol): Check TLS symbol.
+
+--- bfd/elflink.c.tls  2004-09-29 10:34:08.000000000 -0700
++++ bfd/elflink.c      2004-09-29 10:29:41.000000000 -0700
+@@ -709,7 +709,7 @@ _bfd_elf_merge_symbol (bfd *abfd,
+                      bfd_boolean *type_change_ok,
+                      bfd_boolean *size_change_ok)
+ {
+-  asection *sec;
++  asection *sec, *oldsec;
+   struct elf_link_hash_entry *h;
+   struct elf_link_hash_entry *flip;
+   int bind;
+@@ -753,26 +753,31 @@ _bfd_elf_merge_symbol (bfd *abfd,
+       return TRUE;
+     }
+-  /* OLDBFD is a BFD associated with the existing symbol.  */
++  /* OLDBFD and OLDSEC are a BFD and an ASECTION associated with the
++     existing symbol.  */
+   switch (h->root.type)
+     {
+     default:
+       oldbfd = NULL;
++      oldsec = NULL;
+       break;
+     case bfd_link_hash_undefined:
+     case bfd_link_hash_undefweak:
+       oldbfd = h->root.u.undef.abfd;
++      oldsec = NULL;
+       break;
+     case bfd_link_hash_defined:
+     case bfd_link_hash_defweak:
+       oldbfd = h->root.u.def.section->owner;
++      oldsec = h->root.u.def.section;
+       break;
+     case bfd_link_hash_common:
+       oldbfd = h->root.u.c.p->section->owner;
++      oldsec = h->root.u.c.p->section;
+       break;
+     }
+@@ -840,6 +845,54 @@ _bfd_elf_merge_symbol (bfd *abfd,
+   else
+     olddef = TRUE;
++  /* Check TLS symbol.  */
++  if ((ELF_ST_TYPE (sym->st_info) == STT_TLS || h->type == STT_TLS)
++      && ELF_ST_TYPE (sym->st_info) != h->type)
++    {
++      bfd *ntbfd, *tbfd;
++      bfd_boolean ntdef, tdef;
++      asection *ntsec, *tsec;
++
++      if (h->type == STT_TLS)
++      {
++        ntbfd = abfd; 
++        ntsec = sec;
++        ntdef = newdef;
++        tbfd = oldbfd;
++        tsec = oldsec;
++        tdef = olddef;
++      }
++      else
++      {
++        ntbfd = oldbfd;
++        ntsec = oldsec;
++        ntdef = olddef;
++        tbfd = abfd;
++        tsec = sec;
++        tdef = newdef;
++      }
++
++      if (tdef && ntdef)
++      (*_bfd_error_handler)
++        (_("%s: TLS definition in %B section %A mismatches non-TLS definition in %B section %A"),
++         tbfd, tsec, ntbfd, ntsec, h->root.root.string);
++      else if (!tdef && !ntdef)
++      (*_bfd_error_handler)
++        (_("%s: TLS reference in %B mismatches non-TLS reference in %B"),
++         tbfd, ntbfd, h->root.root.string);
++      else if (tdef)
++      (*_bfd_error_handler)
++        (_("%s: TLS definition in %B section %A mismatches non-TLS reference in %B"),
++         tbfd, tsec, ntbfd, h->root.root.string);
++      else
++      (*_bfd_error_handler)
++        (_("%s: TLS reference in %B mismatches non-TLS definition in %B section %A"),
++         tbfd, ntbfd, ntsec, h->root.root.string);
++
++      bfd_set_error (bfd_error_bad_value);
++      return FALSE;
++    }
++
+   /* We need to remember if a symbol has a definition in a dynamic
+      object or is weak in all dynamic objects. Internal and hidden
+      visibility will make it unavailable to dynamic objects.  */
+
index 7f13023e9073202a6d9ec666c56dc7c450d23e03..7cc62f09df42b6caf94a5d957c62b7358996e765 100644 (file)
@@ -1,8 +1,4 @@
 #
-# BUGS:
-#              - http://sources.redhat.com/bugzilla/show_bug.cgi?id=189
-#              - http://sources.redhat.com/bugzilla/show_bug.cgi?id=414
-#
 # Conditional build:
 %bcond_with    allarchs        # enable all targets
 # define addtargets x,y,z      # build with additional targets x,y,z (e.g. x86_64-linux)
@@ -18,7 +14,7 @@ Summary(tr):  GNU geli
 Summary(uk):   îÁ¦Ҡ¦ÎÓÔÒÕÍÅÎԦנGNU ÄÌÑ ÐÏÂÕÄÏ×É ×ÉËÏÎÕ×ÁÎÉÈ ÐÒÏÇÒÁÍ
 Name:          binutils
 Version:       2.15.91.0.2
-Release:       2
+Release:       3
 Epoch:         2
 License:       GPL
 Group:         Development/Tools
@@ -34,6 +30,7 @@ Patch4:               %{name}-pt_pax_flags.patch
 Patch5:                %{name}-mips-relocs.patch
 Patch6:                %{name}-pr290.patch
 Patch7:                %{name}-pr338.patch
+Patch8:                %{name}-pr414.patch
 URL:           http://sources.redhat.com/binutils/
 BuildRequires: autoconf >= 2.59
 BuildRequires: automake >= 1.8.2
@@ -132,6 +129,7 @@ niekt
 %patch5 -p0
 %patch6 -p0
 %patch7 -p1
+%patch8 -p0
 
 %build
 # non-standard regeneration (needed because of gasp patch)
This page took 0.569744 seconds and 4 git commands to generate.