Ignore processor-specific GNU program properties
authorH.J. Lu <hjl.tools@gmail.com>
Tue, 11 Apr 2017 22:07:41 +0000 (15:07 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Tue, 11 Apr 2017 22:07:55 +0000 (15:07 -0700)
Skip processor-specific GNU program properties with generic ELF target
vector.  They should be handled by the matching ELF target vector.

* elf-properties.c (_bfd_elf_parse_gnu_properties): Ignore
processor-specific properties with generic ELF target vector.

bfd/ChangeLog
bfd/elf-properties.c

index d0465623ff0ee6c7f090a5f7c505dfb8f8b7d295..678a00787ed985b3d51371b810bbcb5477c159b5 100644 (file)
@@ -1,3 +1,8 @@
+2017-04-11  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * elf-properties.c (_bfd_elf_parse_gnu_properties): Ignore
+       processor-specific properties with generic ELF target vector.
+
 2017-04-10  Qing Zhao  <qing.zhao@oracle.com>
 
         * elf32-sparc.c (elf_backend_fixup_symbol): New.
index a0456f8df9fadf5c5bf8dc66bc237f372732f808..04ef53625a3552daceb98b805f1a6b9d7de4f408 100644 (file)
@@ -113,7 +113,15 @@ bad_size:
 
       if (type >= GNU_PROPERTY_LOPROC)
        {
-         if (type < GNU_PROPERTY_LOUSER && bed->parse_gnu_properties)
+         if (bed->elf_machine_code == EM_NONE)
+           {
+             /* Ignore processor-specific properties with generic ELF
+                target vector.  They should be handled by the matching
+                ELF target vector.  */
+             goto next;
+           }
+         else if (type < GNU_PROPERTY_LOUSER
+                  && bed->parse_gnu_properties)
            {
              enum elf_property_kind kind
                = bed->parse_gnu_properties (abfd, type, ptr, datasz);
This page took 0.02621 seconds and 4 git commands to generate.