Fix detection of gfortran compilers.
authorBernhard Heckel <bernhard.heckel@intel.com>
Wed, 2 Mar 2016 14:30:05 +0000 (15:30 +0100)
committerBernhard Heckel <bernhard.heckel@intel.com>
Wed, 2 Mar 2016 14:31:20 +0000 (15:31 +0100)
Newer gfortran compilers changed naming convention in DW_AT_producer tag.
For example "GNU Fortran 4.6.3" vs "GNU Fortran2008 5.3.0"

2016-03-02  Bernhard Heckel  <bernhard.heckel@intel.com>

gdb/Changelog:

     * dwarf2read.c (new_symbol_full): Fix detection of gfortran compilers.

gdb/ChangeLog
gdb/dwarf2read.c

index 75c9285a78aba16865240fcf588942114f063410..6538a4a86d70083b176c0f6f1b999e59eefa78e9 100644 (file)
@@ -1,3 +1,7 @@
+2016-03-02  Bernhard Heckel  <bernhard.heckel@intel.com>
+
+       * dwarf2read.c (new_symbol_full): Fix detection of gfortran compilers.
+
 2016-03-01  Andreas Arnez  <arnez@linux.vnet.ibm.com>
 
        * s390-linux-tdep.c (s390_backchain_frame_unwind_cache): Avoid
index 1020c12690bfc0aedfdb916e62c88c755e84af37..dcd49e35ecaa69b2e2d74d9eacc6e44cee68a7d6 100644 (file)
@@ -18506,7 +18506,7 @@ new_symbol_full (struct die_info *die, struct type *type, struct dwarf2_cu *cu,
                  if (cu->language == language_fortran && die->parent
                      && die->parent->tag == DW_TAG_module
                      && cu->producer
-                     && startswith (cu->producer, "GNU Fortran "))
+                     && startswith (cu->producer, "GNU Fortran"))
                    SYMBOL_ACLASS_INDEX (sym) = LOC_UNRESOLVED;
 
                  /* A variable with DW_AT_external is never static,