static bool extended_color_output = false; /* --visualize-jumps=extended-color. */
static int process_links = false; /* --process-links. */
+static int dump_any_debugging;
static int demangle_flags = DMGL_ANSI | DMGL_PARAMS;
/* A structure to record the sections mentioned in -j switches. */
asection *sec;
const char *name;
+ if (!dump_any_debugging)
+ return false;
+
/* If it is already loaded, do nothing. */
if (section->start != NULL)
{
if (!seenflag)
usage (stderr, 2);
+ dump_any_debugging = (dump_debugging
+ || dump_dwarf_section_info
+ || process_links);
+
if (formats_info)
exit_status = display_info ();
else
static bool do_not_show_symbol_truncation = false;
static bool do_demangle = false; /* Pretty print C++ symbol names. */
static bool process_links = false;
+static bool dump_any_debugging = false;
static int demangle_flags = DMGL_ANSI | DMGL_PARAMS;
static int sym_base = 0;
case 'P':
process_links = true;
do_follow_links = true;
+ dump_any_debugging = true;
break;
case 'x':
request_dump (dumpdata, HEX_DUMP);
break;
case 'w':
do_dump = true;
+ dump_any_debugging = true;
if (optarg == NULL)
{
do_debugging = true;
break;
case OPTION_DEBUG_DUMP:
do_dump = true;
+ dump_any_debugging = true;
if (optarg == NULL)
{
do_debugging = true;
Elf_Internal_Shdr * sec;
Filedata * filedata = (Filedata *) data;
+ if (!dump_any_debugging)
+ return false;
+
/* Without section headers we cannot find any sections. */
if (filedata->section_headers == NULL)
return false;