]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
dwarflint: Update code to work with current version of elfutils
authorDjordje Todorovic <djordje.todorovic@rt-rk.com>
Tue, 26 Sep 2017 13:20:04 +0000 (15:20 +0200)
committerMark Wielaard <mark@klomp.org>
Fri, 6 Oct 2017 19:38:48 +0000 (21:38 +0200)
Signed-off-by: Djordje Todorovic <djordje.todorovic@rt-rk.com>
dwarflint/check_debug_line.cc
dwarflint/check_debug_loc_range.cc
dwarflint/dwarflint.cc
dwarflint/files.cc
dwarflint/locstats.cc
dwarflint/misc.hh
dwarflint/reloc.cc

index 34047e2750097ea7f389e9ea06fcaef866cdb0f4..f3d64001f60b15d950680c6dd0fbc8e878e20769 100644 (file)
@@ -513,9 +513,9 @@ check_debug_line::check_debug_line (checkstack &stack, dwarflint &lint)
                    handled = false;
                    switch (extended)
                      {
-#define ONE_KNOWN_DW_LNE(NAME, CODE) case CODE: break;
-                       ALL_KNOWN_DW_LNE
-#undef ONE_KNOWN_DW_LNE
+#define DWARF_ONE_KNOWN_DW_LNE(NAME, CODE) case CODE: break;
+                       DWARF_ALL_KNOWN_DW_LNE
+#undef DWARF_ONE_KNOWN_DW_LNE
                      default:
                        /* No we don't, emit a warning.  */
                        wr_message (op_where, mc_impact_2 | mc_line)
@@ -601,9 +601,9 @@ check_debug_line::check_debug_line (checkstack &stack, dwarflint &lint)
 
              switch (opcode)
                {
-#define ONE_KNOWN_DW_LNS(NAME, CODE) case CODE: break;
-                 ALL_KNOWN_DW_LNS
-#undef ONE_KNOWN_DW_LNS
+#define DWARF_ONE_KNOWN_DW_LNS(NAME, CODE) case CODE: break;
+                 DWARF_ALL_KNOWN_DW_LNS
+#undef DWARF_ONE_KNOWN_DW_LNS
 
                default:
                  if (opcode < opcode_base)
index 5f286226b9dc5ceaa1950a977d2c56dada0c6584..d51fa6ceef64139ad734f8c7c650e915eaae361a 100644 (file)
@@ -673,7 +673,7 @@ namespace
           the CU chain.  So just take the address size of the first CU in
           chain.  */
        struct hole_info hi = {
-         sec->id, cat, ctx.data->d_buf, cu_chain->head->address_size
+         sec->id, cat, ctx.data->d_buf, (unsigned)cu_chain->head->address_size
        };
        coverage.find_holes (0, ctx.data->d_size, found_hole, &hi);
 
index 8067bf41c3cafdf706f3b7dce581a35bba2a26fe..5e07e5b438efe57e53853b8ad39072c393650c76 100644 (file)
@@ -30,6 +30,7 @@
 #include <cstring>
 #include <cerrno>
 #include <stdexcept>
+#include <unistd.h>
 
 std::ostream &
 operator << (std::ostream &o, checkstack const &stack)
index fb74a0e4778beca8db2509f31dd17a7d4a64adc8..b912492f69c956dd545aa7be315dda777d2c01d7 100644 (file)
@@ -28,6 +28,7 @@
 #include <cstring>
 #include <cerrno>
 #include <stdexcept>
+#include <unistd.h>
 
 namespace
 {
index 7602e7fdac2f29202581043154f9c119ae04120e..8a7802b69dc7e693f65ffb94502819107d22f3fa 100644 (file)
@@ -29,6 +29,7 @@
 
 #include <sstream>
 #include <bitset>
+#include <unistd.h>
 
 using elfutils::dwarf;
 
index f779ed61559380daf9741b03590b2f193d4b1f29..86d5836dc0683ee500955a6d5a149e0236684944 100644 (file)
@@ -23,7 +23,7 @@
 
 extern "C"
 {
-#include "../lib/system.h"
+#include "../lib/libeu.h"
 }
 
 #define REALLOC(A, BUF)                                        \
index ec8232dd8e6347f3b9b77e62adcd3f3e81beb192..07686bc48d8e9e9428a002d05d7bcfa27ec3e5a3 100644 (file)
@@ -497,7 +497,7 @@ read_rel (struct elf_file *file,
          if (value != 0)
            wr_message (mc_impact_2 | mc_reloc, &where,
                        ": SHR_RELA relocates a place with non-zero value (addend=%#"
-                       PRIx64", value=%#"PRIx64").\n", rela->r_addend, value);
+                        PRIx64 ", value=%#" PRIx64 ").\n", rela->r_addend, value);
          cur->addend = rela->r_addend;
        }
       else