From 6a57e634bf5c78f8d7297a07bca2a77c4a186ab9 Mon Sep 17 00:00:00 2001 From: Alexandre Oliva Date: Tue, 8 Sep 2009 17:44:50 +0000 Subject: [PATCH] toplev.c (process_options): Choose default debugging type when gtoggle enables debug info and type is unset. * toplev.c (process_options): Choose default debugging type when gtoggle enables debug info and type is unset. From-SVN: r151524 --- gcc/ChangeLog | 5 +++++ gcc/toplev.c | 7 ++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 5bee13ce29cc..c41d08dbd89f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2009-09-08 Alexandre Oliva + + * toplev.c (process_options): Choose default debugging type when + gtoggle enables debug info and type is unset. + 2009-09-08 Alexandre Oliva PR debug/41276 diff --git a/gcc/toplev.c b/gcc/toplev.c index c18965a3c6e3..8a3c4f2635fe 100644 --- a/gcc/toplev.c +++ b/gcc/toplev.c @@ -1883,7 +1883,12 @@ process_options (void) if (flag_gtoggle) { if (debug_info_level == DINFO_LEVEL_NONE) - debug_info_level = DINFO_LEVEL_NORMAL; + { + debug_info_level = DINFO_LEVEL_NORMAL; + + if (write_symbols == NO_DEBUG) + write_symbols = PREFERRED_DEBUGGING_TYPE; + } else debug_info_level = DINFO_LEVEL_NONE; } -- 2.43.5