From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13311 invoked by alias); 29 Jan 2013 22:11:31 -0000 Received: (qmail 13300 invoked by uid 22791); 29 Jan 2013 22:11:30 -0000 X-SWARE-Spam-Status: No, hits=-6.5 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_SPAMHAUS_DROP,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 29 Jan 2013 22:11:23 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r0TMBNuo007581 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 29 Jan 2013 17:11:23 -0500 Received: from host2.jankratochvil.net (ovpn-116-88.ams2.redhat.com [10.36.116.88]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r0TMBIY7020314 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO) for ; Tue, 29 Jan 2013 17:11:21 -0500 Date: Tue, 29 Jan 2013 22:11:00 -0000 From: Jan Kratochvil To: gdb-patches@sourceware.org Subject: [patchv2 13/11] Make relative-with-system-absolute the default Message-ID: <20130129221118.GB27463@host2.jankratochvil.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2013-01/txt/msg00701.txt.bz2 Hi, previous patches discussed it, so make the change with hopefully only pros and no cons. No regressions on {x86_64,x86_64-m32,i686}-fedora19pre-linux-gnu and with gdbindex. Thanks, Jan gdb/ 2013-01-29 Jan Kratochvil * source.c (filename_display_string): Change it to filename_display_relative_with_system_absolute. (_initialize_source): Describe the new "set filename-display" default. gdb/doc/ 2013-01-29 Jan Kratochvil * gdb.texinfo (Backtrace): Change set filename-display default to relative-with-system-absolute. gdb/testsuite/ 2013-01-29 Jan Kratochvil * gdb.threads/linux-dp.exp (first thread-specific breakpoint hit): Allow displayed path for pthread_create.c. --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -6541,7 +6541,7 @@ You can control how file names are displayed. @item set filename-display @itemx set filename-display relative @cindex filename-display -Display file names relative to the compilation directory. This is the default. +Display file names relative to the compilation directory. @item set filename-display basename Display only basename of a filename. @@ -6554,6 +6554,8 @@ Determine whether a source filename comes from file having separate debug information file. In such case display the source filename as absolute one. Otherwise display it relative to the compilation directory. +This is the default. + @item set filename-display basename-with-system-absolute Determine whether a source filename comes from file having separate debug information file. In such case display the source filename as absolute one. --- a/gdb/source.c +++ b/gdb/source.c @@ -127,7 +127,8 @@ static const char *const filename_display_kind_names[] = { NULL }; -static const char *filename_display_string = filename_display_relative; +static const char *filename_display_string = + filename_display_relative_with_system_absolute; static void show_filename_display_string (struct ui_file *file, int from_tty, @@ -2086,7 +2087,7 @@ filename-display can be:\n\ basename-with-system-absolute - display filenames from files with separate\n\ debug info files as absolute, other files\n\ display only with basename of the filename\n\ -By default, relative filenames are displayed."), +By default, relative-with-system-absolute is set."), NULL, show_filename_display_string, &setlist, &showlist); --- a/gdb/testsuite/gdb.threads/linux-dp.exp +++ b/gdb/testsuite/gdb.threads/linux-dp.exp @@ -233,7 +233,9 @@ gdb_continue_to_breakpoint "thread 5's print" # If you do have debug info, the output obviously depends more on the # exact library in use; under NPTL, you get: # #2 0x0012b7fc in start_thread (arg=0x21) at pthread_create.c:264 -gdb_test "where" "print_philosopher.*philosopher.* \(from .*libpthread\|at pthread_create\|in pthread_create\).*" \ +# and with "set filename-display absolute" one gets: +# #2 0x0012b7fc in start_thread (arg=0x21) at /path/to/pthread_create.c:264 +gdb_test "where" "print_philosopher.*philosopher.* \(from .*libpthread\|at pthread_create\|in \[^\r\n\]*pthread_create\).*" \ "first thread-specific breakpoint hit" # Make sure it's catching the right thread. Try hitting the