https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115066

--- Comment #1 from Tom de Vries <vries at gcc dot gnu.org> ---
Looking at the source code, I wonder if this would fix it:
...
diff --git a/gcc/dwarf2out.cc b/gcc/dwarf2out.cc
index eedb13bb069..045858bf638 100644
--- a/gcc/dwarf2out.cc
+++ b/gcc/dwarf2out.cc
@@ -29045,7 +29045,7 @@ output_macinfo_op (macinfo_entry *ref)
          && !DWARF2_INDIRECT_STRING_SUPPORT_MISSING_ON_TARGET
          && (debug_str_section->common.flags & SECTION_MERGE) != 0)
        {
-         if (dwarf_split_debug_info && dwarf_version >= 5)
+         if (dwarf_split_debug_info && (!dwarf_strict || dwarf_version >= 5))
            ref->code = ref->code == DW_MACINFO_define
                        ? DW_MACRO_define_strx : DW_MACRO_undef_strx;
          else
...

Reply via email to